0

When I am running indexer:reindex command, I am getting this error.

Integrity constraint violation: 1062 Duplicate entry '1448-0-1' for key 'PRIMARY', query was: INSERT INTO catalog_product_index_price_temp SELECT catalog_product_index_price_replica.* FROM catalog_product_index_price_replica WHERE (entity_id IN('5472', '5842', '5848', '5467', '5468', '5471', '5848', '5467', '5468', '5851', '5855', '5467', '5471', '5472', '5848', '5467', '5468', '5851', '5855', '5466', '5467', '5468', '1603', '1604', '1605', '1606', '1607', '5472', '5842', '5467', '5468', '5467', '5468', '6214', '6215', '6216', '6217', '1448', '1449', '1450', '1451', '1452', '5696', '5697', '5698', '5699', '5700'))

I tried to disable this product and tried again the command, Again I am getting another set of products as this.

I tried php bin/magento index:reset command, It invalidates the index, and when I am running php bin/magento indexer: reindex it will keep running but not complete.

Any suggestion or help to fix this issue?

2
  • as a trial suggestion, i would recommend you to take the table and DB back up and post that truncate the table 'catalog_product_index_price_replica' once, and then please run the commands... hopefully with the index run it will generate the table values else you have to go out for some further debug to fix it in other ways....bdw for longrun you have to check for some solution but once correctly generated I think the issue will not reoccur so give a try Commented Jan 8 at 7:16
  • @BibhuAsish thanks i will try this
    – Mujahidh
    Commented Jan 9 at 1:22

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.