After upgrading to 1.4.2 I am no longer able to index the Category Products (all other indices work fine). Clearing cache, etc, does not work. The error is:
exception ‘PDOException’ with message ‘SQLSTATE[23000]: Integrity constraints violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`magento/catalog_category_product_index`, CONSTRAINT `FK_CATALOG_CATEGORY_PROD_IDX_CATEGORY_ENTITY` FOREIGN KEY (`category_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON D)’ in /home/public_html/lib/Zend/Db/Statement/Pdo.php:228
There are so many topics and weblogs about index errors and foreign key constraints, after reading almost all of them, I still haven’t found the solutions to my problem.
Give the database repair script a try (http://www.magentocommerce.com/download)
you will however need a clean reference database, so you should install a clean copy of magento somewhere. Once you’re finished with it you can remove the directory but keep the database
Thank you for your reply. At first it seemed to work. After the database was repaired I could reindex the Category Products. Next I tried to refresh the cache to see whether everything was working correctly.
However, now I am locked out of the backend completely! The admin login page gives me an error 404. The front end is still working fine.
I tried accessing the admin panel using index.php/admin, does not work.
I deleted all magento files, reinstalled magento 1.4.2.0 using the previously repaired database, still get the 404 on the admin login page.
I browsed through a lot of topics about error 404 on the admin error page. None of them offer the solution so far.
Anyone experienced this before and knows the solution?
can you access the admin by logging into the downloader and then clicking “return to admin”? also check local.xml to see the admin directory, you can also change it and try logging in with the new name
Renaming did not work, neither does emptying the cache and session folder, a combination of both or any of the other default error fixing procedures.
I think I have tried almost all solutions that are discribed on the web. And I am getting tired of these upgrade bugs, 404 and fatal errors.
Tomorrow I will start with a fresh install. Reconfigure all the stores, recreate all attribute sets, categories, etc and import the 500 products via import/export. Ow, and reupload the product images and of course restore the related/cross/upsells.
Hopefully Magento will become more sustainable from this version on.
I fixed mine in the latest allged stable build. Granted it’s still putting tons of out of stock items as available and allowing people to purchase them, but at least my site is back up sorta.
Make sure you go in and disable all of the Cache then once that’s done go to the index and re-index.
I’m still having issues with products showing up in the main categories though. When you go down to the specific sub-category you can view products, but when at the general category you can’t view any products.