SELECT SQL_CACHE * FROM TERMINE_FASTEN WHERE mandant_id = 1 AND datum_von >= '2017-09-25' AND activity_id IN () ORDER BY datum_von => 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 datum_von' at line 1