1064: SELECT p.id,p.title,p.alt2,p.cprice,p.thumb,p.short,p.price, pc.category as catetitle,c.title as pcname FROM products p INNER JOIN brand_country bc ON p.category=bc.brandid INNER JOIN addedfilters ad ON p.id=ad.p_id LEFT JOIN productcategories pc ON p.category=pc.id LEFT JOIN category c ON p.pc=c.id WHERE (ad.s_id=) AND (ad.pc=2) AND (pc.showbrand=2 || pc.showbrand=3) AND (bc.country_id='5039') AND (p.price>0) AND (p.category=5188) group by p.id order by p.id desc LIMIT 0,20
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 ') AND (ad.pc=2) AND (pc.showbrand=2 || pc.showbrand=3) AND (bc.country_id='' at line 9