Vendor listing error 1064

  • Posts: 134
  • Thank you received: 6
8 years 4 months ago #223436

-- HikaShop version -- : 2.6.0
-- HikaMarket version -- : 1.6.7
-- Joomla version -- : 3.4.5
-- PHP version -- : 5.6.14
-- Error-message(debug-mod must be tuned on) -- : 1064

-- MYSQL version 5.6.27

Hi, as described in the other topic concerning simillar error, this is my bug report about vendor listing menu, regarding the last HM update.

That is the exact message I get:

1064
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'inherit LIMIT 0, 9' at line 1 SQL=SELECT vendor.* FROM mibg_hikamarket_vendor AS vendor WHERE (vendor_published = 1) AND (vendor.vendor_id > 1) ORDER BY vendor.vendor_created inherit LIMIT 0, 9

Regards,
Iliya

Last edit: 8 years 4 months ago by filiar.

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

  • Posts: 26008
  • Thank you received: 4004
  • MODERATOR
8 years 4 months ago #223463

Hi,

In the file "administrator/components/com_hikamarket/helpers/helper.php" please replace in the function "processFilters"

if(empty($orderingAccept) || in_array($t.'.', $orderingAccept) || in_array($this->pageInfo->filter->order->value, $orderingAccept))
	$order = ' ORDER BY '.$this->pageInfo->filter->order->value.' '.strtoupper($this->pageInfo->filter->order->dir);
By
$dir = strtolower($this->pageInfo->filter->order->dir);
if(!in_array($dir, array('asc', 'desc')))
	$this->pageInfo->filter->order->dir = 'ASC';

if(empty($orderingAccept) || in_array($t.'.', $orderingAccept) || in_array($this->pageInfo->filter->order->value, $orderingAccept))
	$order = ' ORDER BY '.$this->pageInfo->filter->order->value.' '.strtoupper($this->pageInfo->filter->order->dir);
It will avoid to insert an "inherit" as the value of the ordering.
Now I don't understand why you have that error because there is check in the view in order to replace the "inherit" by "ASC" ; I tried to reproduce your issue but I couldn't. That's why the patch for the helper will be a good solution.

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: filiar

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

  • Posts: 134
  • Thank you received: 6
8 years 4 months ago #223472

Thank You, Jerome.. That fixed the issue.

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

Moderators: Obsidev
Time to create page: 0.059 seconds
Powered by Kunena Forum