Closed frostedpenguin closed 2 months ago
Care to add the SQL output and what you're expecting?
It's handled by Hibernate, I think you should upgrade your oracle database to at least 12c, then hibernate will use ANSI SQL standard syntax FETCH FIRST m ROWS ONLY
and OFFSET n ROWS FETCH NEXT m ROWS ONLY
instead of ROWNUM
.
Thanks @quaff. As. @quaff mentioned, SQL is generated by Hibernate and there's nothing Spring Data can do about.
@quaff yep you are right it is a legacy db issue, there is no valid SQL that could make this work either way! Anyway, thanks for the response!
I am having this findBy call where I am using distinct through the specification like so
I am adding distinct through the specification
the query generated by hibernate looks like this
the distinct won't work of course because of rownum column! Is this actually possible to be done?