ObjectDB Database Search
51-100 of 200 resultsProblem with distinct select, order by and equivalent alias/attribute path option of build 2 .6.5_03 for disabling the ORDER BY restriction checks:   ... mode I do not. 2 . Even if the exception is NOT thrown (as happening in embedded mode) the order by ... when ordering the results of some projection when the order by expression is different (though logically | |
Cannot sort descending, when ordering by caluculated float in a method Hi, I have found an issue in ordering by a method. I have two entities : Invoice and InvoiceItem ... this query: (I know, it's not very efficient...) select i from Invoice i order by i.getPrice() desc/asc it gives the same order for desc and asc (every time asc) When the float is not calculated (only returned | |
java.lang.NullPointerException when using ORDER BY the ORDER BY? prolancer Emil Andonov Thank you for the details. Please try build 2 .5.4 ... We are using ObjectDB 2 .5.1_04. The following query causes an internal null pointer exception ... == 0)) ORDER BY r.startDateTime DESC If we remove the ORDER BY part, the query completes OK | |
Strange behaviour with ORDER BY and IN performance I noticed a strange behaviour where an ORDER BY - directive isn't executed as it should be (and usually is, except in this special combination-case). Ordering seems to be ignored if we order by a simple member (e.g. a String) being the Entity-ID and, at the same time, filter | |
ORDER BY problem, when String starts with language specific character Dear all, I have a problem with ORDER BY clause. I have a simple query: select u from User u order by u.name When the name starts with "normal/english" character, records are ordered correctly ... anaq x ObjectDB uses the ordinal Java String lexicographical order , which is based on the order | |
NULL prefered in ORDER BY? Hi! Is there a way to NOT prefer NULL in Order BY? I.e. assume this: @Entity class Hint {   ... do something like SELECT FROM Test ORDER BY hint.name It orders ASC like this (assuming I've got ... } and third one to NULL: Test 3 (with hint = NULL) Test 1 (with hint = A ) Test 2 (with hint = B) And descending: Test 2 | |
jakarta.persistence.NamedNativeQuery = "findWidgets", query = "SELECT o.id, o.quantity, o.item " + "FROM Order o, Item i " + "WHERE (o.item = i.id) AND (i.name = 'widget')", resultClass = com.acme. Order .class ) In more complicated cases, a result ... " + "FROM Order o, Item i " + "WHERE (o.quantity 25) AND (o.item = i.id)", resultSetMapping | |
Index Definition is an ordered map data structure that ObjectDB maintains in the file system, not in memory. The B ... scan instead of iterating over all entities. Furthermore, if the field order in the index definition matches the field order in the WHERE clause, ObjectDB can perform a more efficient range scan | |
jakarta.persistence.criteria.ListJoin that has been specified as a java.util.List . Since: Jakarta Persistence (JPA) 2 .0 Public Instance Methods Selection ... . Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ) Create a predicate to test ... - expression to be tested against Returns: predicate testing for equality. Since: Jakarta Persistence (JPA) 3. 2 | |
criteria api / embedded objects / where order to the order of the where clouse and the 2 .7.4 wasn't. Unfortunatly I was not able to strip ... . Because we have different complex queries I did not dare to just change the order for the new version 2 .8.1 but to make sure ... Dear Support Team Changing objectdb from version 2 .7.4 to version 2 .8.1 I found, that query | |
JPA Entity Fields, you can set the order of the retrieved owner entities by using the @OrderBy annotation: @Entity ... Employee e WHERE e.department = :d ORDER BY e.name The specified field ( "name" ) must be a sortable | |
JPA Query Expressions (JPQL / Criteria) JPQL and criteria queries are built on query expressions. Every query consists of clauses , such as SELECT , FROM , WHERE , GROUP BY , HAVING , and ORDER BY . Each clause is composed of JPQL or ... operators, listed in order of decreasing precedence: Navigation operator ( . ) Arithmetic operators | |
JPA Metamodel Attributes . Represents an attribute typed as a java.util.Set , implying unique elements without a specific order . Represents an attribute typed as a java.util.List , supporting ordered collections and index-based | |
JPA Relationships Annotations the ordering and mapping of collection-based relationships using these annotations: Specifies the ordering of elements in a List-valued association at the time of retrieval. Specifies the attribute | |
JPA Criteria API Queries BY and HAVING clauses ( groupBy , having , count , sum , avg , min , max , ...) ORDER BY clause ( orderBy , Order , asc , desc ) The links above go to the Criteria query sections within pages | |
Alias not used in ORDER BY would have expected the alias to be used in the ORDER BY clause, something like SELECT $1, UPPER($1.someStringProperty) AS TEST FROM T ORDER BY TEST However what I actually get as query string is SELECT $1, UPPER($1.someStringProperty) AS TEST FROM T ORDER BY UPPER($1.someStringProperty) This doesn't | |
jakarta.persistence.NamedStoredProcedureQuery must be specified in the order in which they occur in the parameter list of the stored procedure ... . The order of the specification of these mappings must be the same as the order in which the result sets ... StoredProcedureParameter Since: Jakarta Persistence (JPA) 2 .1 Annotation Elements String name The name used to refer | |
jakarta.persistence.criteria.PluralJoin query construction. Since: Jakarta Persistence (JPA) 2 .0 Public Instance Methods Selection alias ... Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ) Create a predicate to test ... to be tested against Returns: predicate testing for equality. Since: Jakarta Persistence (JPA) 3. 2 | |
jakarta.persistence.criteria.MapJoin collection that has been specified as a java.util.Map . Since: Jakarta Persistence (JPA) 2 .0 Public ... of the given basic type. Since: Jakarta Persistence (JPA) 3. 2 Expression entry () Create an expression ... to be tested against Returns: predicate testing for equality. Since: Jakarta Persistence (JPA) 3. 2 | |
jakarta.persistence.criteria.SetJoin that has been specified as a java.util.Set . Since: Jakarta Persistence (JPA) 2 .0 Public Instance Methods Selection ... . Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ) Create a predicate to test ... to be tested against Returns: predicate testing for equality. Since: Jakarta Persistence (JPA) 3. 2 | |
jakarta.persistence.criteria.CollectionJoin that has been specified as a java.util.Collection . Since: Jakarta Persistence (JPA) 2 .0 Public ... of the given basic type. Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ) Create ... . Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Object value ) Create a predicate to test | |
jakarta.persistence.criteria.Join Persistence (JPA) 2 .0 The FROM clause (JPQL / Criteria API) article explains how to use Join . Public ... of the given basic type. Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ) Create ... . Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Object value ) Create a predicate to test | |
jakarta.persistence.JoinColumn Customer class @OneToMany @JoinColumn(name = "CUST_ID") // join column is in the table for Order public Set getOrders() { return orders ; } See Also: ManyToOne OneToMany OneToOne JoinTable ... : "" Since: Jakarta Persistence (JPA) 3. 2 String table (Optional) The name of the table that contains | |
jakarta.persistence.ConstructorResult annotation in the same order as that of the argument list of the constructor. Any entities returned as ... , " + "COUNT(o) as orderCount, " + "AVG(o.price) AS avgOrder " + "FROM Customer c, Orders o ... NamedNativeQuery ColumnResult Since: Jakarta Persistence (JPA) 2 .1 Annotation Elements Class | |
jakarta.persistence.criteria.Root Persistence (JPA) 2 .0 The FROM clause (JPQL / Criteria API) article explains how to use Root ... of the given basic type. Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ... . Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Object value ) Create a predicate to test | |
jakarta.persistence.criteria.From to the type. Since: Jakarta Persistence (JPA) 2 .0 Public Instance Methods Selection alias ( String name ... ) 3. 2 Predicate equalTo ( Expression value ) Create a predicate to test whether the expression ... against Returns: predicate testing for equality. Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo | |
jakarta.persistence.Index ::= column_name [ASC | DESC] If neither ASC nor DESC is not specified, ASC , that is, ascending order ... CollectionTable JoinTable TableGenerator Since: Jakarta Persistence (JPA) 2 .1 Annotation Elements String ... : "" Since: Jakarta Persistence (JPA) 1.0 String columnList (Required) The columns included in the index, in order | |
jakarta.persistence.criteria.Path. Since: Jakarta Persistence (JPA) 2 .0 The Paths and Types in JPQL and Criteria API article explains ... expression of the given basic type. Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ... for equality. Since: Jakarta Persistence (JPA) 3. 2 Predicate equalTo ( Object value ) Create a predicate | |
jakarta.persistence.Column; } Example 2 : @Column(name = "DESC", columnDefinition = "CLOB NOT NULL", table = "EMP_DETAIL") @Lob public String getDescription() { return description; } Example 3: @Column(name = " ORDER _COST", updatable = false, precision = 12, scale = 2 ) public BigDecimal getCost() { return cost; } Portable | |
jakarta.persistence.EntityResult.description " + "FROM Order o, Item i " + "WHERE (o.quantity 25) AND (o.item = i.id)", "OrderItemResults ... .acme. Order .class), @EntityResult(entityClass = com.acme.Item.class) } ) See Also: SqlResultSetMapping ... by the SQL query. Default: LockModeType.OPTIMISTIC Since: Jakarta Persistence (JPA) 3. 2 FieldResult | |
FROM clause (JPQL / Criteria API), LOWER, MAX, MEMBER, MIN, MOD, NEW, NOT, NULL, NULLIF, OBJECT, OF, OR, ORDER , OUTER, POSITION, SELECT | |
JPA Queries the query clauses. Elements used to define the SELECT and ORDER BY clauses. Elements for the FROM | |
What is the Java Persistence API (JPA)? order to interact with a relational database such as Oracle, DB2, SQL Server or MySQL. The popular JPA | |
What are the main benefits of using ObjectDB? that ability and require multiple tables, multiple records and join operations in order to support | |
Query Parameters in JPA for all its parameters. The order in which you set the parameters does not matter. Ordinal | |
Paths and Types in JPQL and Criteria API by all six comparison operators and used for ordering . Navigation through path expressions A path | |
JPA ORM Mapping Annotations a column that is used to maintain the persistent order of a list. Inheritance mapping Define | |
GROUP BY and HAVING clauses The GROUP BY clause groups query results. A JPQL query with a GROUP BY clause returns properties of the resulting groups instead of individual objects and fields. In the query execution order , the GROUP BY clause is processed after the FROM and WHERE clauses but before the SELECT clause | |
Chapter 4 - JPA Queries (JPQL / Criteria) clauses: SELECT , FROM , WHERE , GROUP BY , HAVING , and ORDER BY : The next section explains | |
jakarta.persistence.criteria.CriteriaBuilder.Case Interface used to build general case expressions. Case conditions are evaluated in the order in ... Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ) Create a predicate to test ... against Returns: predicate testing for equality. Since: Jakarta Persistence (JPA) 3. 2 Predicate | |
jakarta.persistence.criteria.CriteriaBuilder.SimpleCase Interface used to build simple case expressions. Case conditions are evaluated in the order in ... Persistence (JPA) 3. 2 Predicate equalTo ( Expression value ) Create a predicate to test ... to be tested against Returns: predicate testing for equality. Since: Jakarta Persistence (JPA) 3. 2 Predicate | |
jakarta.persistence.criteria.CriteriaBuilder.asc(Expression,Nulls) nullPrecedence - the precedence of null values Returns: ascending ordering corresponding to the expression. Since: Jakarta Persistence (JPA) 3. 2 ... Jakarta Persistence (JPA) Method in jakarta.persistence.criteria.CriteriaBuilder Order asc ( Expression expression , Nulls nullPrecedence ) Create an ordering by | |
jakarta.persistence.criteria.CriteriaBuilder.desc(Expression,Nulls) nullPrecedence - the precedence of null values Returns: descending ordering corresponding to the expression. Since: Jakarta Persistence (JPA) 3. 2 ... Jakarta Persistence (JPA) Method in jakarta.persistence.criteria.CriteriaBuilder Order desc ( Expression expression , Nulls nullPrecedence ) Create an ordering by | |
jakarta.persistence.FieldResult.createNativeQuery( "SELECT o.id AS order _id, " + "o.quantity AS order _quantity, " + "o.item AS order _item, " + "FROM Order o, Item i " + "WHERE ( order _quantity 25) AND ( order _item = i.id)", "OrderResults ... . Order .class, fields = { @FieldResult(name = "id", column = " order _id"), @FieldResult(name = "quantity | |
JPA Tutorials Tutorial Only basic Java experience is required in order to follow this tutorial. Web Application | |
Step 3: Define an EJB Session Bean getAllGuests() { TypedQuery query = em.createQuery( "SELECT g FROM Guest g ORDER BY g.id", Guest.class | |
Step 3: Define a Spring DAO Component() { TypedQuery query = em.createQuery( "SELECT g FROM Guest g ORDER BY g.id", Guest.class); return | |
Step 3: Add a Main Class In this step we will add code to the Main class (that was generated with the project) in order to store Point objects in the database and then retrieve them from the database. Use copy and paste to replace the content of the Main class with the following content: package tutorial; import javax | |
Step 3: Define a Spring DAO Component getAllGuests() { TypedQuery query = em.createQuery( "SELECT g FROM Guest g ORDER BY g.id", Guest.class); return | |
Step 3: Define an EJB Session Bean Guest g ORDER BY g.id", Guest.class); return query.getResultList(); } } The GuestDao session bean (EJB |