Being a Magento 2 store admin, you might have faced an error stating,

“Unique Constraint violation found”

In the backend, it looks something like as shown here:

Unique Constraint Violation Found in Magento 2

You may have got integrity constraint violation error while creating an order from the backend in Magento 2 store.

When you face this error, it means that a duplicate value is created in the database table.

Here’s the solution to fix unique constraint violation in Magento 2 admin panel.

Steps to Fix Unique Constraint Violation Found in Magento 2:

Check the table “sequence_order_1” where 1 refers to the store id.


In the above table, the sequence_value column should be auto_increment to fix the integrity constraint violation in Magento 2.

That’s it.

Any doubts about the error and its solution can be mentioned in the Comments section below. I’d be happy to help.

Do share the solution with the Magento Community via social media.

Thank you.

Share This

Share this post with your friends!