donutict Posted November 17, 2017 Share Posted November 17, 2017 Hey, I've suddenly started getting errors when trying to add a new product, such as Unknown column 'product_code' in 'field list' I oepned define_inc and enabled the debugging column, and got this INSERT INTO `psuj_product` (`id_shop_default`, `id_manufacturer`, `id_supplier`, `reference`, `supplier_reference`, `location`, `width`, `height`, `depth`, `weight`, `quantity_discount`, `ean13`, `upc`, `cache_is_pack`, `cache_has_attachments`, `is_virtual`, `id_category_default`, `id_tax_rules_group`, `on_sale`, `online_only`, `ecotax`, `minimal_quantity`, `price`, `wholesale_price`, `unity`, `unit_price_ratio`, `additional_shipping_cost`, `customizable`, `text_fields`, `uploadable_files`, `active`, `redirect_type`, `id_product_redirected`, `available_for_order`, `available_date`, `condition`, `show_price`, `indexed`, `visibility`, `cache_default_attribute`, `advanced_stock_management`, `date_add`, `date_upd`, `pack_stock_type`, `product_code`) VALUES ('1', '0', '0', '', '', '', '0', '0', '0', '0', '0', '', '', '0', '0', '0', '2', '0', '0', '0', '0', '1', '0', '0', '', '0', '0', '0', '0', '0', '1', '404', '0', '1', '0000-00-00', 'new', '1', '0', 'both', '0', '0', '2017-11-17 03:22:10', '2017-11-17 03:22:10', '3', '') Nothing has been modified or changed at all, not sure how to fix it though! Thanks Link to comment Share on other sites More sharing options...
bellini13 Posted November 17, 2017 Share Posted November 17, 2017 what is product_code and what version of prestashop are you using? Link to comment Share on other sites More sharing options...
NemoPS Posted November 17, 2017 Share Posted November 17, 2017 I've seen that though I can't quite remember where it came from. product_code was added by a module I believe. Check modules -> positions (1.6) and see if anything is hooking do displayAdminProductsExtra or ProductUpdate Link to comment Share on other sites More sharing options...
donutict Posted November 17, 2017 Author Share Posted November 17, 2017 10 minutes ago, NemoPS said: I've seen that though I can't quite remember where it came from. product_code was added by a module I believe. Check modules -> positions (1.6) and see if anything is hooking do displayAdminProductsExtra or ProductUpdate Hey, thanks for the response! There’s things hooked to both of those, although the displayAdminProducts has one which was for a module I do not use, so I unhooked it. The second has Top sellers block, new products block etc which have all been there since the start. Unfortunately I’m still getting the error any other ideas? Link to comment Share on other sites More sharing options...
donutict Posted November 17, 2017 Author Share Posted November 17, 2017 18 minutes ago, bellini13 said: what is product_code and what version of prestashop are you using? not sure what it is and I’m using 1.6.1.17 Link to comment Share on other sites More sharing options...
bellini13 Posted November 18, 2017 Share Posted November 18, 2017 product_code is not a core field for Prestashop. So while you say nothing has been modified or changed, certainly something has. Link to comment Share on other sites More sharing options...
donutict Posted November 18, 2017 Author Share Posted November 18, 2017 Just now, bellini13 said: product_code is not a core field for Prestashop. So while you say nothing has been modified or changed, certainly something has. The theme was changed the day before, could that have changed something important then? Link to comment Share on other sites More sharing options...
bellini13 Posted November 18, 2017 Share Posted November 18, 2017 what was changed? you mean you installed a new theme? or you changed the existing theme. Either way, you likely have a module or customization performed to your store that is not functioning properly. Link to comment Share on other sites More sharing options...
donutict Posted November 18, 2017 Author Share Posted November 18, 2017 Just now, bellini13 said: what was changed? you mean you installed a new theme? or you changed the existing theme. Either way, you likely have a module or customization performed to your store that is not functioning properly. I uploaded a new theme, activated it and deleted the old one, I’ll see if there’s any modules that I don’t recognise just in case Link to comment Share on other sites More sharing options...
bellini13 Posted November 18, 2017 Share Posted November 18, 2017 Go to your file system on the server, go to the modules folder, and look at the timestamps of the module folders. Look for anything that has a recent date on or after the date/time you installed the theme. Link to comment Share on other sites More sharing options...
NemoPS Posted November 19, 2017 Share Posted November 19, 2017 Also another easy way would be to check the theme's package's modules/ folder, and see which ones it comes with Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now