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 a.act=\'Y\'\' at line 1
select count(*) as cnt from catalogue as a left join `download_imgs` as b on(a.mainimg=b.id) left join `catalogue` as c on(a.parent_id=c.id) left join `catalogue` as d on(c.parent_id=d.id) left join `basket_tmp` as e on(a.id=e.catalogue and e.sid=\'a5fe341b9496c9db6fdffacea0aef82e\') where a.catalogue_type=1 and a.public=\'Y\' and a.parent_id in () and a.act=\'Y\'
Произошла ошибка при обращении к базе данных.