select * from green_ctbrands where ctbrand_id in(510,481,466,472,470,487,513,553,722,563,581,617,595,652,715,716,745,760,464,785)and ctbrand_id not in () order by ctbrand_title asc
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 ') order by ctbrand_title asc' at line 1