About CriteriaBuilder

forum_thread

Error using query with MAX() function

I have a class that is persisting a Entity that holds remarks and a time. Then when I query for the latest remark I get a internal error when the remark is larger than 1966 chars. Here is a test class and entity that reproduces the problem on my system. ... ) . begin ( ) ; CriteriaBuilder cb = em. getCriteriaBuilder ( ) ; ...

 
forum_thread

Will ObjectDB support JPA 2.1 CriteriaDelete?

Code like this: CriteriaBuilder cb = getEntityManager().getCriteriaBuilder(); CriteriaDelete<AlertEntity> criteriaDelete = cb.createCriteriaDelete(entityClass); Throws: java.lang.UnsupportedOperationException at com.objectdb.jpa.criteria.CriteriaBuilderImpl.createCriteriaDelete(CriteriaBuilderImpl.java:1508) ... Code like this: CriteriaBuilder cb = getEntityManager ( ) . ...

 
forum_thread

Query in JPA2 with LEFT JOIN on INNER JOIN

select a.description, a.id, p1.description, p2.description,p3.description from action a left join action_profile ap1 on ap1.id_action=a.id inner join profile p1 on  ap1.id_profile=p1.id  and p1.name='?' left join action_profile ap2 on ap2.id_action=a.id inner join profile p2 on  ap2.id_profile=p2.id  and p2.name='?' where a.id =?;   Thanks   ... Hi, this is my critera query: CriteriaBuilder cb = entityManager. getCriteriaBuilder ( ...

 
forum_thread

Calendar in Criteria Querys

Hi, i am having troubles creating criteria querys for Calendar objects. As far as I can see CriteriaBuilder has no methods for checking if one Calendar is bevor or after another. Javas Calendar Class got such methods, but i dont know how to use those in my query. ... criteria querys for Calendar objects. As far as I can see CriteriaBuilder has no methods for checking if one Calendar is bevor or after ... . commit ( ) ;   CriteriaBuilder cb = em. getCriteriaBuilder ( ) ; ...

 
forum_thread

Help with JPA2 Criteria and conditional operator grouping

Hi,   I'm getting a little trouble performing a query as per the way I had it set up on eclipselink. Essentially, the query I'm trying to generate is: SELECT $1 FROM Company $1 WHERE (($1.companyId=:p1) AND ($1.conditionOne=true)) AND (($1.conditionTwo=false) OR ($1.conditionThree=false))   From the JPA2 criteria: ...   From the JPA2 criteria: CriteriaBuilder builder = em. getCriteriaBuilder ( ) ...

 
forum_thread

CriteriaQuery using isNotNull with other conditions results in InternalException

When I try to execute the following criteria query   ... to execute the following criteria query CriteriaBuilder builder = em. getCriteriaBuilder ( ) ...

 
manual

ORDER BY clause (JPQL / Criteria API)

Explains how to use the ORDER BY clause in a JPA/JPQL query.... = cb. createQuery createQuery(resultClass) CriteriaBuilder's method Create a CriteriaQuery object with the specified ... Page... ( cb. asc asc(x) CriteriaBuilder's method Create an ordering by the ascending value of the ...

 
issue

Null pointer exception being thrown from within ObjectDB.

EXCEPTION/DESCRIPTION:... SOURCE CODE: ----------------- ... CriteriaBuilder cb = entityManager. getCriteriaBuilder ( ...

 
api-jpa

Criteria Query Selection and Results

Reference (JavaDoc) of JPA query criteria result interfaces, including Selection, CompoundSelection, Order and Tuple.... - either ascending (ASC) or descending (DESC). The CriteriaBuilder javax.persistence.criteria.CriteriaBuilder JPA interface Used to construct criteria queries, ...

 
forum_thread

Threading Problem (maybe with Criteria)

Hi all I found some threading problems I do not understand: here is the the link to the testcase http://www.advolux.de/weblink%20forum/test.zip ... ) ; instead of Criteria API CriteriaBuilder cbuilder = manager. getCriteriaBuilder ( ...