Page 1 of 1

Error No: 1146

Posted: Mon Mar 16, 2009 3:16 pm
by DavideSheeley
Error: Table 'xxxxxx.product_to_image' doesn't exist
Error No: 1146
DELETE FROM product_to_image WHERE product_id = '40'


http://localhost/admin/index.php?route=catalog/product

When I try to delete the default products I get the 1146 error. I searched for it in the forum and couldn't find anything.

Re: Error No: 1146

Posted: Mon Mar 16, 2009 3:58 pm
by fido-x
In "admin/model/catalog/product.php", line 148, change from --

Code: Select all

$this->db->query("DELETE FROM product_to_image WHERE product_id = '" . (int)$product_id . "'");
to

Code: Select all

$this->db->query("DELETE FROM product_image WHERE product_id = '" . (int)$product_id . "'");

Re: Error No: 1146

Posted: Sat Oct 30, 2010 9:11 am
by theone
hi, im having this error any body help?

Error: Table 'unlocks1_ocart.zone_to_geo_zone' doesn't exist
Error No: 1146
SELECT tr.tax_class_id, tr.rate AS rate, tr.description, tr.priority FROM tax_rate tr LEFT JOIN zone_to_geo_zone z2gz ON (tr.geo_zone_id = z2gz.geo_zone_id) LEFT JOIN geo_zone gz ON (tr.geo_zone_id = gz.geo_zone_id) WHERE (z2gz.country_id = '0' OR z2gz.country_id = '222') AND (z2gz.zone_id = '0' OR z2gz.zone_id = '3563') ORDER BY tr.priority ASC

Re: Error No: 1146

Posted: Sat Oct 30, 2010 3:07 pm
by i2Paq
Always mention version of your OpenCart!

Re: Error No: 1146

Posted: Sun Oct 31, 2010 1:34 am
by jones
if you didn't delete any database table/query at before then just try to repair and optimize your OC database from your database manager .e.g phpmyadmin

Re: Error No: 1146

Posted: Sun Oct 31, 2010 11:58 am
by theone
hi, im using the latest version which is opencart_v1.4.9.1
i tried to repair db but still same problem and i also tried to clean install but unfortunately its same problem..
any help?

regards

Re: Error No: 1146

Posted: Sun Oct 31, 2010 4:21 pm
by theone
also tried with 1.4.9.2 but still same

can anybody help?