About predicate

api-jpa

JPA Queries

Reference (JavaDoc) of all the JPA query types, including Query, TypedQuery, CriteriaBuilder, CriteriaQuery, Tuple, Root, Expression, Order, etc. Queries are represented in JPA by the Query and TypedQuery interfaces: javax.persistence.Query javax.persistence.TypedQuery The JPA Query API section (in chapter 4 of the ObjectDB manual) provides ...

 
forum_thread

IMK Stall with certain query

Hello, I am experiencing constant IMK Stall notifications from Java when using certain query: 2015-09-01 16:53:15.785 java[3678:5217999] IMK Stall detected, *please Report* your user scenario in <rdar://problem/16792073> - (imkxpc_deadKeyStateWithReply:) block performed very slowly (4.63 secs) i am sure it is linked with objectdb as these are thrown each time one particular query is used: ... query . FROM ( OrderData . class ) ; Predicate p1 = cb . LIKE ( cb . lower ( ORDER . ... "buyerId" ) ) , param ) ; Predicate p2 = cb . LIKE ( cb . lower ( ORDER . ...

 
manual

Numbers in JPQL and Criteria Queries

Shows how numbers, arithmetic expressions and numeric functions and operators (MOD, ABS) can be used in JPQL queries. Numeric values may appear in JPQL queries in many forms: as  numeric literals - e.g. 123 , -12.5 . as parameters - when numeric values are assigned as arguments. as  path expressions ...

 
api-jpa

in(expression)

Create predicate to test whether given expression is contained in a list of values.(Method of javax.persistence.criteria.CriteriaBuilder)

 
forum_thread

multiple LEFT JOINs do not work as expected

Hi, We have a hierarchical data set of organisations in the database, where each organisation stores a reference to it parent organisation. I'm trying to find all organisations 2 levels under a root organisation, e.g. where organisation.parentOrg is the root or organisation.parentOrg.parentOrg is the root. The query also contains a number of other predicates and it is built dynamically using Criteria API. It could be looking for other number of levels, 2 is just an example. The test query looks like this: #1 2011-12-16 05:41 Hi, We have a hierarchical data set of organisations in the database, where each organisation stores a re ...

 
api-jpa

value(value)

Add to list of values to be tested against.(Method of javax.persistence.criteria.CriteriaBuilder.In)

 
forum_thread

JPA 2.0 Criteria API: (When) Fully supported ?

An excerpt from the website of a 3rd party vendor which tries to support JPA 2.0:   "The primary difference between JPA 1.0 and JPA 2.0 implementations is how data is fetched: the JPA 1.0 implementation creates a JPQL query string for fetching while the JPA 2.0 implementation uses Criteria API.   Tested JPA 2.0 providers #1 2012-02-23 13:27 An excerpt from the website of a 3rd party vendor which tries to support JPA 2.0:   "The prim ...

 
manual

SELECT clause (JPQL / Criteria API)

Explains how to use the SELECT clause and projections in a JPA/JPQL query. The ability to retrieve managed entity objects is a major advantage of JPQL. For example, the following query returns Country objects that become managed by the EntityManager javax.persistence.EntityManager JPA interface Inte ...

 
issue

New Java 8 (JDK 1.8) Collection Methods

ObjectDB version 2.5.5 (and above) supports Java 8 (JDK 1.8). Tracking changes to collections and maps using some new Java 8 methods is currently not fully supported. The main known issue is that orphan removal does not happen as a result of removing a reference to an object (which becomes an orphan) using the new methods: removeIf(predicate) and remove(key, value). ... becomes an orphan) using the new methods:  removeIf(predicate) and remove(key, value). ObjectDB ...

 
api-jpa

value(value)

Add to list of values to be tested against.(Method of javax.persistence.criteria.CriteriaBuilder.In)