About Criteria API


How to use JOIN FETCH?

The ObjectDB manual (http://www.objectdb.com/java/jpa/query/jpql/from) gives an example of using JOIN FETCH to avoid excessive round trips to the database: #1 2012-08-21 13:41 The ObjectDB manual ( http://www.objectdb.com/java/jpa/query/jpql/from ) gives an example of using JOIN FETCH t ...


TYPE Expression

Hi there! Trying to add a simple type expression with the criteria api like in your sample: cb.notEqual(e.type(), cb.literal(Country.class)); results in the error: Caused by: com.objectdb.o.UserException: Attempt to store an instance of a non persistable type java.lang.Class at com.objectdb.o.MSG.d(MSG.java:61) at com.objectdb.o.TYW.writeElement(TYW.java:223) at com.objectdb.o.QRR.l(QRR.java:424) at com.objectdb.o.QRR.g(QRR.java:230) at com.objectdb.o.QRR.b(QRR.java:151) ... Trying to add a simple type expression with the criteria api like in your sample: cb. equal ( e. type ( ) ...


migration path from JPA / Hibernate

Hi. Is there a conversion tool or documentation that is of help when migrating an existing JPA solution to ObjectDB? Any recommendations or known pitfalls when it comes to ...   ... ObjectDB website) for exact details. Notice that the JPA 2 criteria query API is now fully supported (relevant documentation will be released in a ...



A join to an entity, embeddable, or basic type.(Interface of JPA)



Represents a simple or compound attribute path from a bound type or collection, and is a "primitive" expression.(Interface of JPA)



A root type in the from clause.(Interface of JPA)


ObjectDB 2.6 Developer's Guide

... applications using ObjectDB and JPA (Java Persistence API). The main purpose of this guide is to make you productive with ObjectDB ... objects. Chapter 4 - JPA Queries (JPQL / Criteria) Explains how to use the JPA Query Language (JPQL). ...



Get the current lock mode for the query.(Method of javax.persistence.Query)


Optimization of Map Queries

hi! I am having loads and loads of occurrences of something like ((com.test.MyEntity) $1.map.get('com.test.MyEntity')).someProperty ... ((com.test.MyEntity) $1.map.get('com.test.MyEntity')).someOtherProperty .. ((com.test.MyEntity) $1.map.get('com.test.MyEntity')).someMoreProperties I need to use full qualified names for casting as well as for the map keys because same entity simple names may occur multiple times. Now I've got two questions: ... such a join variable look like? And how to create it using criteria api? We do have heavy usage of maps so I'd appreciate any ...


Issue with DISTINCT Select

It is getting more and more frustrating :( We've introduced distinct select instead of regular selection in our code (no changes else) and suddenly receive invalid identifiers in queries exceptions in various queries. Here's the stacktrace: ... are used for both: Explicit variables in criteria queries. Implicit variables that are generated as a ... = class com . quasado . foundation . contact . api . model . individual . IndividualContact ) ) ORDER ...