We are experiencing this problem on a Sybase DB as well.
Can the SQL be generated to use "||" instead of "," in between the composite primary key fields?
For example:
select count((user0_.field1|| user0_.field2)) as col_0_0_ from User user0_
instead of:
select count((user0_.field1, user0_.field2)) as col_0_0_ from User user0_
I've created a Hibernate interceptor like the previous poster, to modify all SQL to use count instead, but I wonder if a better fix would be to do it in the custom dialect.
We are experiencing this problem on a Sybase DB as well.
Can the SQL be generated to use "||" instead of "," in between the composite primary key fields?
For example:
select count((user0_.field1|| user0_.field2)) as col_0_0_ from User user0_
instead of:
select count((user0_.field1, user0_.field2)) as col_0_0_ from User user0_
I've created a Hibernate interceptor like the previous poster, to modify all SQL to use count
instead, but I wonder if a better fix would be to do it in the custom dialect.