0

How is the sales_flat_order.entity_id determined and is there a safe way for me to start it at a higher number?

We just changed versions of magento and have an external ERP. Becuase the orders are created using entity_id we are getting duplicate order issues. I would like to start entity_id where the last site left off?

0

This information is stored in eav_entity_store and can be edited there.

To change the entity_id you need to change the AUTO_INCREMENT value of a database, this can be done via a SQL query:

ALTER TABLE `sales_flat_order` AUTO_INCREMENT = 5;

On a short search through the magento codebase and Varien_Ddl and Pdo stuff I didn't found anything to do it via a method.

  • Hmm I'm using 1.8 and it's not there. I'm not looking for 'increment_last_id' but am looking for 'entity_id'. – willboudle May 30 '14 at 15:43
  • oh, sorry. Updated. – Fabian Blechschmidt May 30 '14 at 15:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.