MySQL error on step 3 of checkout process

  • Posts: 5
  • Thank you received: 0
8 years 1 month ago #251778

Hi,

I have been receiving an error for a while now with regards to the checkout process. This only seems to occur around 25% of the time and it happens when clicking the finish button on step 3 of the checkout process. I receive a 404 an this is the error that is displayed in the developer console.

Failed to load resource: the server responded with a status of 500 (Unknown column 'products' in 'field list' SQL=INSERT IGNORE INTO `#__hikashop_order` ( `order_user_id`,`order_status`,`order_shipping_address_id`,`order_billing_address_id`,`order_discount_code`,`order_currency_id`,`order_currency_info`,`order_type`,`order_full_price`,`order_shipping_price`,`order_shipping_tax`,`order_discount_tax`,`order_discount_price`,`order_payment_id`,`products`,`order_created`,`order_ip`,`order_modified` ) VALUES ( '24','created','215','215','code30','4','O:8:\"stdClass\":4:{s:13:\"currency_code\";s:3:\"GBP\";s:13:\"currency_rate\";s:7:\"1.00000\";s:20:\"currency_percent_fee\";s:4:\"0.00\";s:17:\"currency_modified\";s:10:\"1473026825\";}','sale','0','0','0','0','2.6','0',',','1475842103','188.65.100.234','1475842103' ))

If you hit the back button and hit finish again then this error go's away. Obviously I cannot tell customers to do this. Has anyone come accross this issue before or know how I might go about resolving it?

Thanks in advance
Lucas

Last edit: 8 years 1 month ago by Jerome. Reason: [code] is nice

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13378
  • MODERATOR
8 years 1 month ago #251784

Hi,

You could go in your PHPMyAdmin, open the table hikashop_order and add a new column "products" so that this MySQL query wouldn't fail.
However, the real problem here is that it tries to use that variable as a column when it shouldn't. Would you have some other extension integrated with HikaShop which might lead to that issue ? If you disable the hikashop and system plugins one by one can you find a culprit where you wouldn't have the problem anymore if you disabled it ?

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 1 month ago #251912

Thanks Nicolas,

I was hoping adding the column would resolve this issue but it seems to have no affect. With regards to plugins then I am currently not using any with Hikashop, just the standard standalone install.

Lucas

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 1 month ago #251914

Hi,

Knowing that the value which is trying to be set is

','
You can add the column in the database with the type "varchar(50)".
But that is absolutely sure that it is the best way to fix the problem, just trying to avoid it.

HikaShop is using the element "products" in the order object ; but that field is an array of products object so it will be automatically skip during he save.
The fact that this variable is replaced by a " ',' " is not part of the HikaShop code.
Please be sure that you're using the latest HikaShop version and you do not have specific overrides or unusual system plugins.
You can also perform some tests using the default Joomla template.

REgards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 1 month ago #252144

Thanks for your response,

So I am unable to get this working by adding the column products. Which is strange as if I run the following SQL query against the database then it inserts fine.

INSERT IGNORE INTO  `josof_hikashop_order` (  `order_user_id` ,  `order_status` ,  `order_shipping_address_id` ,  `order_billing_address_id` ,  `order_discount_code` ,  `order_currency_id` ,  `order_currency_info` ,  `order_type` ,  `order_full_price` ,  `order_shipping_price` ,  `order_shipping_tax` , `order_discount_tax` ,  `order_discount_price` ,  `order_payment_id` ,  `products` ,  `order_created` ,  `order_ip` ,  `order_modified` ) 
VALUES (
'24',  'created',  '215',  '215',  'code30',  '4',  'O:8:\"stdClass\":4:{s:13:\"currency_code\";s:3:\"GBP\";s:13:\"currency_rate\";s:7:\"1.00000\";s:20:\"currency_percent_fee\";s:4:\"0.00\";s:17:\"currency_modified\";s:10:\"1473026825\";}',  'sale',  '0',  '0',  '0',  '0',  '2.6',  '0',  ',',  '1475842103',  '188.65.100.234',  '1475842103'
)

I will try test this scenario again later with the default template and see if it is something that the Titania template is doing.

Thanks again for your help on this.

Lucas

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 1 month ago #252702

So I have done a little more digging on this issue and was able to recreate the same issue with the default template. The issue only occurs when signing in during the checkout process. If you was to complete the order already signed in then this error does not occur.

Any help on this would be appreciated.

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13378
  • MODERATOR
8 years 1 month ago #252753

Hi,

We're not able to reproduce the problem on our end.
So you said that for some orders it worked fine, but for some other orders it didn't.
Do you see a difference between the two types of orders ?
For example, it only happens for orders with products with variants, or only for orders with a shipping method, or something like that ?
It would really help to narrow down the list of possibilities.
Could it be that you have some mass actions configured ? What if you deactivate them ? Do you still have the problem ?
What if you deactivate all the system and hikashop plugins ? Do you still have the problem ?

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
8 years 1 month ago #252807

Hi,

So as I mentioned in my previous post this issue only occurs when signing in during the checkout process. This is the little login form that displays below the checkout table. If a user was to already be signed in then this error doesn't happen.

It also makes no difference what product is purchased and in what category. Have tried disabling all hikashop plugins and this still happens.

Is there a way to remove the login functionality from that page and have it redirect to the login page before you can checkout?

Thanks in advance.

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13378
  • MODERATOR
8 years 1 month ago #252896

Hi,

1. I don't see why the login during the checkout would generate that error. Could you provide a link to the shop and a test user account so that we could look at the problem ?

2. What you can do is configure a menu item of the type "HikaShop checkout" and select it in the "force menu on checkout" setting.
If you set that menu item's access level to registered, when someone try to access the checkout, it will redirect them to the login page of Joomla.

Please Log in or Create an account to join the conversation.

Time to create page: 0.068 seconds
Powered by Kunena Forum