What's New
Viewing 2 posts - 1 through 2 (of 2 total)
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic.
Tagged: Easybuilder
Hi:
With latest version installed (with previous happened too), when you go in the Backoffice to Eeasybuilder => Catalog tab. You have selected for example Product description, an type something in the edit text. The jquery request returns error 500 always.
After digging the problem is with the SQL query generated, i enabled the debug mode in prestashop backoffice and this is the returned response to the jquery request:
<p>
<b>SQLSTATE[42000]: Syntax error or access violation: 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 'desc LIMIT 50 'at line 9</b>
<br/>
<i>at line </i>
<b>151</b>
<i>in file </i>
<b>classes/db/DbPDO.php</b>
</p>
The query with the error is:
SELECT *
FROM <code>ps_product</code> p
INNER JOIN ps_product_shop product_shop
ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1)
LEFT JOIN <code>ps_product_lang</code> pl ON (pl.id_product = p.id_product AND pl.id_lang = 1 AND pl.id_shop = 1 )
LEFT JOIN <code>ps_image_shop</code> image_shop
ON (image_shop.<code>id_product</code> = p.<code>id_product</code> AND image_shop.cover=1 AND image_shop.id_shop=1)
LEFT JOIN <code>ps_image_lang</code> il ON (image_shop.<code>id_image</code> = il.<code>id_image</code> AND il.<code>id_lang</code> = 1)
WHERE 1 AND (pl.name LIKE '%test%'OR p.reference LIKE '%test%') GROUP BY p.id_product desc LIMIT 50
The problem is with the desc, has no sense as is not being sorted the query…
Hi,
Please replace the \classes\data\provider\Product.php file with my attached one.
Best regards.
You must be logged in to reply to this topic.