为给定类别或 SKU 编号制定折扣/购物车规则时,无法保存并创建此错误:
'Zend_Db_Statement_Exception' with message 'SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`shop1`.`salesrule_product_attribute`, CONSTRAINT `FK_SALESRULE_PRD_ATTR_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`customer_group_i)' in /var/www/shop1/public_html/lib/Zend/Db/Statement/Pdo.php:234
我一直在查看我的数据库以找到问题,但没有运气。我不确定现在从哪里开始查找,我在 customer_group 表中没有发现明显的错误,但我认为这与前一段时间删除的店面有关,可能弄乱了客户 ID?