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 '' at line 9

select distinct p.products_id, p.products_price, p.products_tax_class_id,p.products_image, pd.products_name,s.specials_new_products_price, s.status as specials_status, IF(s.status = '1' AND s.stores_id = '1', s.specials_new_products_price, p.products_price) as final_price from products p left join specials s on p.products_id = s.products_id and s.status = 1 and stores_id = 1 join products_description pd on p.products_id = pd.products_id and pd.language_id = 0 join products_to_stores p2s ON p.products_id = p2s.products_id and p2s.stores_id = 1 join products_stock ps on p.products_id = ps.products_id and ps.products_stock_quantity > 0 where p.products_status = 1 and ((pd.products_name like '%%')) || (p.products_id=0) ORDER BY pd.products_name asc LIMIT 0,

[TEP STOP]