builder « Criteria « JPA Q&A





1. Work around for lack of sqlProjection support within criteria builder?    stackoverflow.com

http://jira.grails.org/browse/GRAILS-2803 concerns lack of support for sqlProjection. It was closed as a duplicate and supposedly fixed in Grails v1.2. But the "duplicate" issue concerned sqlRestriction and I do not ...

2. criteria builder bug    forum.hibernate.org

Hi: I use criteria builder to build queries including filtering and sorting. All works fine, but using filtering on numeric columns, criteria builder create queries with LITERAL EXPRESSIONS. I have test on 4 databases: oracle xe, mysql 5, hsqldb (in memory) and derby 10.5 (in memory). For example, in oracle XE, using this code: CriteriaBuilder criteriaBuilder = entityManager.getCriteriaBuilder(); CreteriaQuery criteriaQuery = ...