Magento: Item (Mage_Sales_Model_Order) with the same id "1" already exist - magento-1.7

After I migrate my Magento shop from one hosting provider to another one. Before I start to migrate a delete all my test orders and put counter of order number to 0.
I have big problem. When I want to go in back office into sales->order I get an error "There has been an error processing your request
Exception printing is disabled by default for security reasons.
Error log record number: 213759415"
If I go into var/report and open file "213759415" I see 36 lines the first one are:
a:5:{i:0;s:64:"Item (Mage_Sales_Model_Order) with the same id "1" already exist";i:1;s:5345:"#0 /usr/home/xxx/domains/xxx.com/public_html/lib/Varien/Data/Collection/Db.php(576): Varien_Data_Collection->addItem(Object(Mage_Sales_Model_Order))
I have Magento 1.7.0.2
Any ideas?
Many thanks!

I found in db, tabel called "onestepcheckout" where I forgot to delete test orders.

Make sure you properly deleted all test orders.
You can use the following module to do this:
http://www.magentocommerce.com/magento-connect/asperience-deleteorders.html

Related

User is getting "You tried to lock table '' while opening it, but the table cannot be locked because it is currently in use."

Getting this error, with no table listed, when the user logs in to the order system.
The query is, roughly
SELECT FormParts.*, qrySomeOtherColumns.*, CBool(0) AS ObjMissing INTO Temp_SessionFormParts
FROM FormParts INNER JOIN qrySomeOtherColumns ON FormParts.ID = qrySomeOtherColumns.FormPartID
WHERE EmpId = EmpID();
The data is coming from linked tables with a Postgres back end.
The data is going into the local table "Temp_SessionFormParts"
This is a local table in the front end, so no one else should have access to it.
Everyone else has a copy of the same database, but no one else gets the error.
Where it gets weird is that she only gets the error when she starts the app with our standard shortcut that copies the latest version.
copy "\\NASdiskstation\Install\Deploy\pgFrontEnd.accde" "C:\Merge Documents\"
start "" MSAccess.exe "C:\Merge Documents\pgFrontEnd.accde"
But if she starts Access from the Start Menu, and then opens the same database from the selections, it works fine.
Seems to me that those two routes should give the same result since she's already copied the latest to C:.
I went ahead an posted this question, since I had it written up, because I've seen this error a few times. So this may be helpful.
Normally, you can't SELECT INTO an existing table. But Access detects that situation and helpfully deletes the table before executing the insert.
Somehow this was failing.
DROP TABLE Temp_SessionFormParts
before the INSERT fixed the issue.
No idea why it sometimes didn't work for some people or why running Access directly changed that.

Power Automate - Update Work Item Error - Response in JSON Format -Azure Devops

I am getting an exception when I am trying to update an existing work item description with a link of SharePoint file in power automate. This SharePoint file had been created when an email with the attachment was received.
Please have a look at the flow and exception below
Can anyone please help me understand the issue?
Thanks,
Bee
It looks like you entered a wrong variable for the field Work Item Id. The field Work Item Id for step Update a work item should be the id of the work item to update.
I saw you set the field Work Item Id to variable {x}workItemUrl. If variable workItemUrl is not the work item id. The automate flow will fail with above error.
You can also check the log to see if the values you specified in the fields are correct.

Get ARAccountRef is invalid when adding second invoice for the same customer

I have invoices that add ok but will not sync. Below is the error I get back from SyncStatusRequest. Research suggests this error is related to payments but I am adding invoices. And stranger still, I only seem to have this problem when I add two invoices in a row for the same customer (1st is fine, 2nd will not sync). Anyone have any ideas?
QBXML validation error:
[severity=FATAL_ERROR,message=cvc-complex-type.2.4.a:
Invalid content was found starting with element 'ARAccountRef'. One of '{CustomerRef}' is expected.,
locator=url=null,
line=-1,
column=-1,
node=null,
object=com.intuit.sb.datasync.writeback.qbxml.schema.ARAccountRef#392ac48b,
field=null]
]

Issue with Vendor and Employee Business Rules

According to the documentation, there is a Business Rule for Vendor and Employee that says
The name, first name, or last name field should not be blank.
Considering that NAME is required for create, the question is ¿Does this mean that ALL three properties have to have a value on Create?
We understood that, so we ran some tests. Creating a record with the three properties populated has no problem. The issue comes when we try so insert a null value for GivenName and FamilyName (first name and last name).
Quickbooks seems to take the NULL values as valid, and when inserting the record is not returning any error. The problem is that the record that was inserted never shows in the QBD UI, but is seems like it persists somewhere, because if we try to insert it again we get a "duplicate name" error.
Not sure if this is an issue or an expected behaviour... Any hints??
Thanks
QuickBooks for windows has some legacy behavior to be aware of. The First, Last and Name combines for a unique identifier accross Customers, Vendors and Employees. So you should fill in ALL the information you have. Any attempts to insert a record with the same F or L name, will fail if there is a Customer, Vendor or Employee with the same F & L.
Second, you mentioned that the record doesn't show in QuickBooks for Windows?
Did it sync successfully? Did you check the error state of the record you inserted?
Did you look at the sync logs to see if it failed to sync?
Lastly, you need to check all three objects for a user with the same F & L name if you are getting a duplicate error. Normally you would check to see if the customer/vendor/employee exists firsts so you can update the existing or determine if it is in fact a new record.
hope that helps
Jarred

Magento getting error on product flat data reindixing

Getting this error
while reindexing using ssh command
exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 1005 Can't create table './admin_magento16/catalog_product_flat_4.frm' (errno: 150)' in /home/magesite/public_html/store/lib/Zend/Db/Statement/Pdo.php:228
in my magento database there is no catalog_product_flat_4 table is present
what should I need to do for this?
Did you clean Magento cache before reindexing?
I can recommend you to check your database with original Magento Database Repair Tool
able to solve this problem with our team
1st I checked database
checked the core_store table there are 4 store created
also the catalog_product_flat_2 , 3 , 4 tables are missed
I checked my admin panel there is only 1 store
so create the sites from admin panel add added the catalog_product_flat_2 , 3 , 4
then re-index is works fine
cheers :)