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 '), 'Y', 'N') as flag FROM categories_description WHERE categories_id IN (248) OR' at line 1
in:
[SELECT categories_id, categories_name, IF(categories_id IN (), 'Y', 'N') as flag FROM categories_description WHERE categories_id IN (248) ORDER BY categories_name]