ObjectDB ObjectDB

Internal Website Search

1-10 of 200 resultsRefresh
203

Collections in JPQL and Criteria Queries

Collections may appear in JPQL queries: as parameters - when collections are assigned as arguments. as path expressions - in navigation to persistent collection fields. IS [NOT] EMPTY The IS [NOT] EMPTY operator checks whether a specified collection is empty or not. For example: c.languages
54

get(collection)

Method javax.persistence.criteria.Path Expression<C> get( PluralAttribute<X,C,E> collection ) Create a path corresponding to the referenced collection-valued attribute. Parameters: collection - collection-valued attribute Returns: expression corresponding to the referenced attribute Since: JPA 2.0
54

isNotMember(elem, collection)

, Expression<C> collection ) Create a predicate that tests whether an element is not a member of a collection. If the collection is empty, the predicate will be true. Parameters: elem - element expression collection - expression Returns: is-not-member predicate Since: JPA 2.0
54

isMember(elem, collection)

, Expression<C> collection ) Create a predicate that tests whether an element is a member of a collection. If the collection is empty, the predicate will be false. Parameters: elem - element expression collection - expression Returns: is-member predicate Since: JPA 2.0
54

isMember(elem, collection)

Method javax.persistence.criteria.CriteriaBuilder Predicate isMember( E elem, Expression<C> collection ) Create a predicate that tests whether an element is a member of a collection. If the collection is empty, the predicate will be false. Parameters: elem - element collection - expression Returns: is-member predicate Since: JPA 2.0
54

isMember(elem, collection)

, Expression<T> collection ) Create a predicate that tests whether an element is a member of a collection. If the collection is empty, the predicate will be false. Parameters: elem - element expression collection - expression Returns: is-member predicate Since: JPA 2.0
54

isNotMember(elem, collection)

, Expression<T> collection ) Create a predicate that tests whether an element is not a member of a collection. If the collection is empty, the predicate will be true. Parameters: elem - element expression collection - expression Returns: is-not-member predicate Since: JPA 2.0
54

isNotMember(elem, collection)

Method javax.persistence.criteria.CriteriaBuilder Predicate isNotMember( E elem, Expression<C> collection ) Create a predicate that tests whether an element is not a member of a collection. If the collection is empty, the predicate will be true. Parameters: elem - element collection - expression Returns: is-not-member predicate Since: JPA 2.0
54

size(collection)

Method javax.persistence.criteria.CriteriaBuilder Expression<Integer> size( C collection ) Create an expression that tests the size of a collection. Parameters: collection - collection Returns: size expression Since: JPA 2.0
7

[ODB1] Chapter 7 - JDOQL Queries

: A candidate collection containing persistent objects (usually an Extent) A candidate class (usually ... is a subset of objects from the candidate collection that contains only the instances of the candidate class ... is 18 or older: Query query = pm.newQuery(Person.class, "this.age >= 18"); Collection result

Getting Started

ObjectDB is very easy to use. Follow the Getting Started Tutorial and the Quick Tour manual chapter and in minutes you may be able to write and run first Java programs against ObjectDB.

Prior knowledge or experience in database programming (SQL, JDBC, ORM, JPA, etc.) is not required, but some background in using the Java language is essential.

Need Help?

  1. Search ObjectDB website
  2. Read the FAQ
  3. Follow the Tutorials
  4. View or post in the forum
  5. Search or file an issue
  6. Contact support