Cannot Run the Query:
SELECT distinct(offers.brands_id) as brands_id from tbl_offers offers where offers.enddatetime>='2012-02-08 14:27:29' and offers.category_id in () and published='1'
order by startdatetime desc, enddatetime desc, offers.offer_id
as following error is encountered...
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 published='1'
order by startdatetime desc, enddatetime desc, offe' at line 1