3

Is there a way to trigger a DB schema update?

I've just copied the live DB which is 1.8 to a development host which has 1.9.3.3 installed. The frontend is displaying correctly but I can't get into /admin as some of the metadata tables are missing columns.

For example I'm getting the following logged in var/report

a:5:{i:0;s:698:"SQLSTATE[42S22]: Column not found: 1054 Unknown column 'sales_bestsellers_aggregated_yearly.product_type_id' in 'field list', query was: SELECT COUNT(*) FROM (SELECT MAX(DATE_FORMAT(period, '%Y-%m-%d')) AS period, SUM(qty_ordered) AS qty_ordered, sales_bestsellers_aggregated_yearly.product_id, MAX(product_name) AS product_name, MAX(product_price) AS product_price, sales_bestsellers_aggregated_yearly.product_type_id FROM sales_bestsellers_aggregated_yearly WHERE (EXISTS (SELECT 1 FROM catalog_product_entity AS existed_products WHERE (sales_bestsellers_aggregated_yearly.product_id = existed_products.entity_id))) AND (store_id IN(0)) GROUP BY product_id LIMIT 5) AS t";i:1;s:5064:"#0 /public_html/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)

4

I resolved my issue using n98-magerun sys:setup:incremental this ran through the update scripts.

  • n98-magerun is indeed a live saving tool, a must have for Magento. – Deus777 Sep 1 '17 at 9:22
0

Try deleting your local.xml and do installation again.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.