Hi,
I use hibernate-core-3.6.3 && hibernate-jpa-2.0-api-1.0.0.Final
I have found a bug in hibernate with setMaxResult and setFirstResult with LEFT JOIN FETCH hql query. Hibernate is not able to create the query for doing the LIMIT/OFFSET in the query. Thus, Hibernate does the filtering in memory (it generates a warning message for it).
It's the filtering in memory which is bugged.
For getting the right result i use this code :
Code:
List<Object> resultList = (List<Object>) query.getResultList();
return resultList.subList(start, Math.min(start + end, resultList.size()));
There is a bugzilla web site for creating a bug report ?
Cordially,
Sylvain