MYSQL Error after updating from Essentials to Bus

  • Posts: 11
  • Thank you received: 0
10 years 6 months ago #178349

-- HikaShop version -- : 2.3.4
-- Joomla version -- : 3.1.1
-- PHP version -- : 5.3.29
-- Browser(s) name and version -- : Firefox 33.0.2
-- Error-message(debug-mod must be tuned on) -- : 1253 COLLATION 'utf8_general_ci' is not valid for CHARACTER SET 'latin1' SQL=SELECT a.*,b.*,c.*,IFNULL(c.name COLLATE utf8_general_ci,CONCAT_WS(' ',d.address_firstname,d.address_middle_name,d.address_lastname)) AS hikashop_name FROM leca0_hikashop_order AS b LEFT JOIN leca0_hikashop_address AS d ON b.order_billing_address_id=d.address_id LEFT JOIN leca0_hikashop_user AS a ON b.order_user_id=a.user_id LEFT JOIN leca0_users AS c ON a.user_cms_id=c.id WHERE (b.order_type='sale') ORDER BY b.order_id desc LIMIT 0, 30

I am getting the MYSQL error after upgrading from Essentials to Business on the ORDERS Page. The Orders page worked fine before on Essnetials. If i re-install essentials I can get the Orders page to work, but I purchased the Business version upgrade and need it for email settings and such.

Thanks

1253 COLLATION 'utf8_general_ci' is not valid for CHARACTER SET 'latin1' SQL=SELECT a.*,b.*,c.*,IFNULL(c.name COLLATE utf8_general_ci,CONCAT_WS(' ',d.address_firstname,d.address_middle_name,d.address_lastname)) AS hikashop_name FROM leca0_hikashop_order AS b LEFT JOIN leca0_hikashop_address AS d ON b.order_billing_address_id=d.address_id LEFT JOIN leca0_hikashop_user AS a ON b.order_user_id=a.user_id LEFT JOIN leca0_users AS c ON a.user_cms_id=c.id WHERE (b.order_type='sale') ORDER BY b.order_id desc LIMIT 0, 30

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

  • Posts: 11
  • Thank you received: 0
10 years 6 months ago #178366

I also tested the installation another test account and got the same error message. I upgraded using the Essentials to Business update packet which I had essentials already installed.

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

  • Posts: 26232
  • Thank you received: 4035
  • MODERATOR
10 years 6 months ago #178383

Hi,

Can you please check your database using "PHPMyAdmin".
The table "leca0_users" should be in collation "utf8_general_ci" but it looks like regarding your error message that the table (or just the field) is in "latin1" collation.

The problem you have is not with the upgrading from Essential to Business but the update from 2.3.3 to 2.3.4.

You can fix the problem by editing the file "administrator/components/com_hikashop/views/order/view.html.php" and replace

$database->setQuery('SELECT a.*,b.*,c.*,IFNULL(c.name COLLATE utf8_general_ci,CONCAT_WS(\' \',d.address_firstname,d.address_middle_name,d.address_lastname)) AS hikashop_name '.$query,(int)$pageInfo->limit->start,(int)$pageInfo->limit->value);
By
$database->setQuery('SELECT a.*,b.*,c.*,IFNULL(c.name,CONCAT_WS(\' \',d.address_firstname,d.address_middle_name,d.address_lastname)) AS hikashop_name '.$query,(int)$pageInfo->limit->start,(int)$pageInfo->limit->value);

I will report your issue to Nicolas who submit the fix during September.

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.
The following user(s) said Thank You: southpaw3229

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

  • Posts: 11
  • Thank you received: 0
10 years 6 months ago #178572

That worked. I did see that my users table was using latin, which i changed and added the new snippet of code and all is good now.

Thanks

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

  • Posts: 159
  • Thank you received: 2
10 years 5 months ago #180124

Hi,
I do receive a similar error in the backend when I try to access my orders. It happened after updating to 2.3.4. I changed the code as advised in this thread. The SQL table uses UTF-8, but it's still not working. This is the error message:

1253 COLLATION 'utf8_general_ci' is not valid for CHARACTER SET 'latin1' SQL=SELECT a.*,b.*,c.*,IFNULL(c.name COLLATE utf8_general_ci,CONCAT_WS(' ',d.address_firstname,d.address_middle_name,d.address_lastname)) AS hikashop_name FROM mmp_jomkas_hikashop_order AS b LEFT JOIN mmp_jomkas_hikashop_address AS d ON b.order_billing_address_id=d.address_id LEFT JOIN mmp_jomkas_hikashop_user AS a ON b.order_user_id=a.user_id LEFT JOIN mmp_jomkas_users AS c ON a.user_cms_id=c.id WHERE (b.order_type='sale') ORDER BY b.order_id desc LIMIT 0, 20

Thanks
Roger

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

  • Posts: 159
  • Thank you received: 2
10 years 5 months ago #180128

Hi,
just fixed it by reloading the original file and for some reason it works now. Very strange....

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

Time to create page: 0.072 seconds
Powered by Kunena Forum