cancel
Showing results for 
Search instead for 
Did you mean: 

Getting an error, has anyone seen this before?

Getting an error, has anyone seen this before?

SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`stitchdirect_db`.`salesrule_product_attribute`, CONSTRAINT `FK_SALESRULE_PRD_ATTR_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`custo)

1 REPLY

Re: Getting an error, has anyone seen this before?

Hi,

 

This table is used for Shopping Cart Price Rules based on some product attribute. The error could mean that something is trying to insert or update a rule for non-existing or not properly created/deleted customer group. Have you deleted customer groups recently?

 

To fix this error go into Admin Panel, open and re-save all Shopping Cart Price Rules.

-------Store Manager for Magento 1.x and 2.x - enhances the functionality of default admin web interface, speeds up inventory management, automates daily tasks.