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 (14,15,19,27,41,102,180,183,190,246,263,270,310,320,322,324,325,326,573,672,681,683,684,688,692,697,700,709,716,717,718,721,801,832,911,1021,1022,1026,1027,1036,1037,1057,1090,1177,1183,1191,1194,1199,1293,1360,1361,1475,1476,1477,1479,1483,1484,1485,1486,1487,1490,1492,1494,1495,1496,1584,1695,1921,1939,2091,2263,2375,2383,2401,2408,2658,2918,2921,2935,2938,2940,2946,2966,2971,2972,2985,3021,3063,3137,3140,3141,3262,3297,3320,3347,3348,3350,3417,3424,3473,3589,3629,3643,3648,3862,4082,4097,4275,4354,4378,4432,4434,4449,4455,4518,4522,4602,5218,5622,6012,6016,6144,6170,6317,6357,6388,6498,6504,6508,6549,6639,6811,6822,6937,7057,7074,7097,7574,7577,7689,7888,7906,7930,8037,8041,8102,8237,8367,8381,8430,8435,8437,8442,8912,8956,8997,9088,9167,9426,9461,9752,9754,9813,9929,9965,9985,10483,10563,10642,10788,10975,11077,11300,11303,12084,12222,12433,12447,12571,12575,12892,12939,12941,13318,14063,14385,14418,14481,14482,14586,14889,15107,15110,15930,16078,16176,16224,16350,16720,16722,17017,17019,17025,17031,17032,) 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 (14,15,19,27,41,102,180,183,190,246,263,270,310,320,322,324,325,326,573,672,681,683,684,688,692,697,700,709,716,717,718,721,801,832,911,1021,1022,1026,1027,1036,1037,1057,1090,1177,1183,1191,1194,1199,1293,1360,1361,1475,1476,1477,1479,1483,1484,1485,1486,1487,1490,1492,1494,1495,1496,1584,1695,1921,1939,2091,2263,2375,2383,2401,2408,2658,2918,2921,2935,2938,2940,2946,2966,2971,2972,2985,3021,3063,3137,3140,3141,3262,3297,3320,3347,3348,3350,3417,3424,3473,3589,3629,3643,3648,3862,4082,4097,4275,4354,4378,4432,4434,4449,4455,4518,4522,4602,5218,5622,6012,6016,6144,6170,6317,6357,6388,6498,6504,6508,6549,6639,6811,6822,6937,7057,7074,7097,7574,7577,7689,7888,7906,7930,8037,8041,8102,8237,8367,8381,8430,8435,8437,8442,8912,8956,8997,9088,9167,9426,9461,9752,9754,9813,9929,9965,9985,10483,10563,10642,10788,10975,11077,11300,11303,12084,12222,12433,12447,12571,12575,12892,12939,12941,13318,14063,14385,14418,14481,14482,14586,14889,15107,15110,15930,16078,16176,16224,16350,16720,16722,17017,17019,17025,17031,17032,) and agatti_films.active=1