Fix for Magento issue: (SQLSTATE[22003]: Numeric value out of range: 1690 BIGINT UNSIGNED value is out of range in (DB_NAME.q.items_count – 1)

By finding this page, you most likely have had the same issue when trying to delete products, real or dummy in a new Magento install. The error when attempting to delete products from the admin section.

The error message in the admin:

SQLSTATE[22003]: Numeric value out of range: 1690 BIGINT UNSIGNED value is out of range in '('DB_NAME'.'q'.'items_count' – 1)'

How to Fix:

1. Go into your database using PhpMyAdmin.

2. Do a backup/export (optional – but always good practice).

3. Select the Magento database you are using (if using multiple databases – ignore if single database).

4. Select the table: sales_flat_quote.

(ignore the xsva in my example, it’s just a db prefix)

4. Open the ‘structure’ tab

Screen Shot 2015-09-18

5. Select ‘change’ on row called ‘items_count’.

6. In the ‘Attributes’ drop-down column, change value to the very top value which is blank ‘(no value)’, as opposed to the default selection ‘UNSIGNED‘ .

Screen Shot 2015-09-18 at 13.09.33

Click save, and then you’re good to go!

You should now be able to delete your products with error-free. Hope this helps!

Useful post? Share it

Leave a Reply

Your email address will not be published.