(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 ') and 1 and t.displayorder>=0 \x0D\x0AORDER BY t.displayorder desc, t.dateline' at line 7
SELECT t.*,p.message,mf.customstatus,mf.medals,c.collection FROM forum_thread t JOIN forum_post p on t.tid=p.tid and p.first=1 LEFT JOIN common_member_field_forum mf on mf.uid=t.authorid left join forum_collectionrelated c on t.tid=c.tid where t.fid in () and 1 and t.displayorder>=0 ORDER BY t.displayorder desc, t.dateline desc LIMIT 0 ,