Reputation: 1791
We’re facing a few problems when trying to update product in Magento at the moment.
What we’ve done so far to eliminate any problems:
Everything was working on site great, then we’ve seen something that needs updating in all of our products so we’re trying to re-import our products to update the existing products.
This is where we’re experiencing some issues:
Does anyone have any ideas on why this is happening? what it the error message actually saying?
Upvotes: 1
Views: 2890
Reputation: 96
How are you updating the products? Are you using the product import or dataflow? There is a primary key(s) on the table. The manner in which you are doing the import is trying to add the products and not update them. Since the primary key must be unique, you are trying to put a new record in with an existing primary key. That's what the SQL error is...
Go into the Magento admin, under System > Import/Export > Export. That will get you all the data in the correct format. Make your changes. Then go back and do an import.
On the import screen select 'Replace Complex Data' as the import behavior. I would backup the database first and test it out on a dev environment, but that is the correct way to handle it.
Upvotes: 1