1

我已将 Magento Enteprise 1.13.0.0 的补丁文件添加到我的 Magento Enteprise 1.12.0.2 中出现 eorrr SQLSTATE[42S02]: Base table or view not found: 1146 Table 'catalog_category_flat' does not exist 并且还按照指示对表进行了更改通过http://www.hassmann-software.de/mysql-workbench-lost-connection-to-mysql-server-after-600-seconds/但仍然得到同样的错误。我无法打开任何管理页面。

并且还在Magento Answers上发布了这个问题

Magento 错误

4

1 回答 1

-2
SET SQL_SAFE_UPDATES=0;
DELETE
FROM catalog_category_entity_datetime
WHERE catalog_category_entity_datetime.attribute_id NOT IN (
    SELECT eav_attribute.attribute_id FROM eav_entity_type
     INNER JOIN eav_attribute ON eav_attribute.entity_type_id = eav_entity_type.entity_type_id
     WHERE (eav_entity_type.entity_type_code='catalog_category')
);

DELETE
FROM catalog_category_entity_decimal
WHERE catalog_category_entity_decimal.attribute_id NOT IN (
    SELECT eav_attribute.attribute_id FROM eav_entity_type
     INNER JOIN eav_attribute ON eav_attribute.entity_type_id = eav_entity_type.entity_type_id
     WHERE (eav_entity_type.entity_type_code='catalog_category')
);
DELETE
FROM catalog_category_entity_int
WHERE catalog_category_entity_int.attribute_id NOT IN (
    SELECT eav_attribute.attribute_id FROM eav_entity_type
     INNER JOIN eav_attribute ON eav_attribute.entity_type_id = eav_entity_type.entity_type_id
     WHERE (eav_entity_type.entity_type_code='catalog_category')
);

DELETE
FROM catalog_category_entity_text
WHERE catalog_category_entity_text.attribute_id NOT IN (
    SELECT eav_attribute.attribute_id FROM eav_entity_type
     INNER JOIN eav_attribute ON eav_attribute.entity_type_id = eav_entity_type.entity_type_id
     WHERE (eav_entity_type.entity_type_code='catalog_category')
);

DELETE
FROM catalog_category_entity_varchar
WHERE catalog_category_entity_varchar.attribute_id NOT IN (
    SELECT eav_attribute.attribute_id FROM eav_entity_type
     INNER JOIN eav_attribute ON eav_attribute.entity_type_id = eav_entity_type.entity_type_id
     WHERE (eav_entity_type.entity_type_code='catalog_category')
);



SET SQL_SAFE_UPDATES=0;
TRUNCATE TABLE catalog_category_entity_datetime;
TRUNCATE TABLE catalog_category_entity_decimal;
TRUNCATE TABLE catalog_category_entity_int;
TRUNCATE TABLE catalog_category_entity_text;
TRUNCATE TABLE catalog_category_entity_varchar;
TRUNCATE TABLE core_url_rewrite;
于 2013-07-29T08:52:01.537 回答