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 agatti_films.active=1' at line 1
select agatti_films.genre1,agatti_films.genre2,agatti_films.genre3,agatti_films.genre4,agatti_films.genre5,agatti_films.genre6,agatti_films.genre7,agatti_films.genre8,agatti_films.genre9,agatti_films.genre10 from agatti_films where id in (25,35,47,140,244,256,302,308,360,405,457,594,664,684,712,740,759,824,1169,1170,1172,1191,1283,1284,1297,1430,1460,1520,1521,1522,1712,1898,2107,2175,2176,2214,2398,2412,2492,2497,2537,2556,2836,3004,3011,3044,3047,3068,3160,3273,3275,3278,3280,3282,3323,3497,3511,3759,3774,4076,4159,4314,4347,4379,4434,4448,4450,4585,4602,4633,4643,4655,4778,4822,4824,5087,5162,5163,5239,5248,5268,5598,5621,5660,6014,6087,6167,6350,6549,6612,6644,6869,6870,6871,6873,6874,6875,7954,8017,8047,8172,8431,8513,8597,8602,8736,8906,9088,9146,9153,9631,9984,9995,10113,10719,10963,10995,12589,12590,12852,12943,13120,13180,13590,13808,14144,14430,14481,14483,14761,14812,14996,15546,15649,15905,16108,16344,16410,16614,16616,17137,17239,17566,19144,19393,19397,19626,19630,20524,20935,21831,21875,21877,21879,21911,22191,22197,22402,22438,22484,22504,22668,22688,22702,22705,22748,22895,22896,22897,22898,23094,23111,23112,23261,23265,23267,23286,23445,23523,23863,23908,23933,24040,24312,24329,24382,24383,24384,24507,24534,24608,24644,24834,) and agatti_films.active=1
select agatti_films.genre1,agatti_films.genre2,agatti_films.genre3,agatti_films.genre4,agatti_films.genre5,agatti_films.genre6,agatti_films.genre7,agatti_films.genre8,agatti_films.genre9,agatti_films.genre10 from agatti_films where id in (25,35,47,140,244,256,302,308,360,405,457,594,664,684,712,740,759,824,1169,1170,1172,1191,1283,1284,1297,1430,1460,1520,1521,1522,1712,1898,2107,2175,2176,2214,2398,2412,2492,2497,2537,2556,2836,3004,3011,3044,3047,3068,3160,3273,3275,3278,3280,3282,3323,3497,3511,3759,3774,4076,4159,4314,4347,4379,4434,4448,4450,4585,4602,4633,4643,4655,4778,4822,4824,5087,5162,5163,5239,5248,5268,5598,5621,5660,6014,6087,6167,6350,6549,6612,6644,6869,6870,6871,6873,6874,6875,7954,8017,8047,8172,8431,8513,8597,8602,8736,8906,9088,9146,9153,9631,9984,9995,10113,10719,10963,10995,12589,12590,12852,12943,13120,13180,13590,13808,14144,14430,14481,14483,14761,14812,14996,15546,15649,15905,16108,16344,16410,16614,16616,17137,17239,17566,19144,19393,19397,19626,19630,20524,20935,21831,21875,21877,21879,21911,22191,22197,22402,22438,22484,22504,22668,22688,22702,22705,22748,22895,22896,22897,22898,23094,23111,23112,23261,23265,23267,23286,23445,23523,23863,23908,23933,24040,24312,24329,24382,24383,24384,24507,24534,24608,24644,24834,) and agatti_films.active=1