【发布时间】:2015-03-30 11:58:09
【问题描述】:
我来了
违反完整性约束:1452 无法添加或更新子行: 外键约束失败 (database_name.catalog_category_product_index, 约束 FK_CAT_CTGR_PRD_IDX_PRD_ID_CAT_PRD_ENTT_ENTT_ID 外键 (product_id) REFERENCES catalog_product_entity (entity_id) ON DEL)' in /home/digitales/public_html/lib/Zend/Db/Statement/Pdo.php:234 错误 同时在 Magento 中重新索引 Category 产品。
我正在使用命令行中的 php indexer.php --reindex catalog_category_product 命令重新编制索引。
我已经尝试过查询 -
SELECT * FROM catalog_category_product WHERE
product_id not in (select entity_id from catalog_product_entity);
给出 0 个结果。
也试过了
SELECT * FROM catalog_category_product WHERE
category_id not in (select entity_id from catalog_category_entity);
这也给出了 0 结果。
谢谢, 仁
【问题讨论】:
标签: php mysql magento indexing