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 '1542,1287,1259,1299,1267,1249,1257,1252,1269,1261,1277,1359,1358,1343,1303,1283,' at line 1
in:
[select * from categories where categories_id in (,1542,1287,1259,1299,1267,1249,1257,1252,1269,1261,1277,1359,1358,1343,1303,1283,1302,1244)]