Since the update from Hibernate 5.0.6 to 5.0.7 our queries using ORDER BY FIELD won't work anymore. It throws java.sql.SQLException: Operand should contain 1 column(s)
The Query simply is:
SELECT e FROM MyEntity e WHERE e.id IN (:ids) ORDER BY FIELD(id, :ids)
The generated SQL shows a difference:
5.0.6: ... order by FIELD(id, ?, ?, ?)
5.0.7: ... order by FIELD(id, (?, ?, ?))
Thanks in advance!
Ubuntu Linux 15.10, Java 8, Hibernate 5.0.7, MySQL Driver 5.1.34