Hi, I have migrated categories and products from M1 to M2. And it shows finished on M2 backend.
But when I try to reindex data, it shows:
Category Products index process unknown error:
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘1307-1543’ for key ‘PRIMARY’, query was: INSERT INTO `temp_catalog_category_tree_index_4ab6b35d` (`parent_id`,`child_id`) VALUES (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?)
Product Categories index process unknown error:
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘1307-1543’ for key ‘PRIMARY’, query was: INSERT INTO `temp_catalog_category_tree_index_9357d6f9` (`parent_id`,`child_id`) VALUES (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?), (?, ?)
Can you please help?
1 answer
Hi there,
Product Categories index process unknown error:
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘1307-1543’ for key ‘PRIMARY’, query was: INSERT INTO `temp_catalog_category_tree_index_9357d6f9`
Please try to reindex your data following these steps:
1. Run the CLI command:
php -f bin/magento indexer:reset
2. And then, you run the CLI command:
php -dmemory_limit=-1 -f bin/magento indexer:reindex
And let me how it goes then.
Regards,
Mall.