Jump to content

Unknown column ERROR after confirming order


CSEpe
 Share

Recommended Posts

Since a few days we get this error.

Fatal error: Uncaught Unknown column 'id_shop' in 'field list'<br /><br /><pre> SELECT id_customer, customer_email, id_shop, id_lang FROM `ps_mailalert_customer_oos` WHERE `id_product` = 339 AND `id_product_attribute` = 0</pre> thrown in /home/public_html/classes/db/Db.php on line 791

There is no id_shop in this table. Nor in the old backups

When I disable mailalerts module payment by Paypal and Bank works but cash gives error:

Catchable fatal error: Argument 4 passed to ToolsCore::displayPrice() must be an instance of Context, boolean given, called in /home/public_html/modules/cash/cash.php on line 360 and defined in /home/public_html/classes/Tools.php on line 637

So after disabling Cash module v 0.3 by Librasoft  and Mailalerts module it works again.

 

Edited by CSEpe (see edit history)

Share this post


Link to post
Share on other sites

It is about two independent errors.

1) The ps_mailalert_customer_oos table should have this schema:

CREATE TABLE IF NOT EXISTS `ps_mailalert_customer_oos` (
  `id_customer` int(10) unsigned NOT NULL,
  `customer_email` varchar(128) NOT NULL,
  `id_product` int(10) unsigned NOT NULL,
  `id_product_attribute` int(10) unsigned NOT NULL,
  `id_shop` int(10) unsigned NOT NULL,
  `id_lang` int(10) unsigned NOT NULL,
  PRIMARY KEY (`id_customer`,`customer_email`,`id_product`,`id_product_attribute`,`id_shop`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

Share this post


Link to post
Share on other sites

Hi,

Go to go to modules and reset the mailalerts module, this will fix your database table structure for the ps_mailalert_customer_oos table. After that you will not have this issue.

If this will not fix your issue, then the problem is in the Cash module . Your Catchable fatal error from the Cash module can be fixed easily, I can help you with that after you have solved the "Fatal error: Uncaught Unknown column" error.

Regards, Leo

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More