About results

forum_thread

Slow searching with two indexes

I'm running queries on a large database (tens of millions of objects), and I'm running into a performance problem using two indexes.  An entity I'm querying has two indexed fields - one is the primary key (id) and so is different for each object, and the other is an object reference that only has a few tens of different values.   When I query by just the primary key, it's (of course) extremely fast, but when I also query using the other key, queries can take minutes.... id desc  With the query limited to (say) 10 results. Is there any obvious way to speed up this querying? ... ) .   [ Step 2 ] Order the results of step 1 by: desc ( any ( any ( this.id ) ...

 
api-jpa

getResultList()

Execute a SELECT query and return the query results as an untyped List.(Method of javax.persistence.Query)

 
api-jdo

javax.jdo.annotations.Query

Annotation for a named query.(Annotation of JDO)

 
issue

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: ... Invalid order expression '$3' for distinct results at com.objectdb.o.MSG.d(MSG.java:61) at ... the query is invalid because you are trying to order the results based on a field of $2 - after eliminating $2 from the results. Notice that if profile is a collection then the same $1 value may ...

 
manual

JPA Query API

Describes the API that JPA provides for running queries against the database.... result type is unknown or when a query returns polymorphic results and the lowest known common denominator of all the result objects is ... It is easier to run queries and process the query results in a type safe manner when using the TypedQuery interface. ...

 
forum_thread

Caching/Paging Questions...

Greetings ObjectDB team, All below questions assume a very large database (~1,000,000,000 objects): Q1: Two queries with a big overlap between their result sets. If I query the first set and hold the results in memory somehow, would that speed up the execution of the second query since many of its result objects already created and reside in memory ?... their result sets. If I query the first set and hold the results in memory somehow, would that speed up the execution of the second ... (the EntityManager L1 cache) but instantiation of the results (if they contain entity objects) are slightly faster if relevant ...

 
forum_thread

Explorer in 2.3

First, the new Explorer in ObjectDB is fantastic! This is exactly what we've needed - an easy way to do ad-hoc JPQL queries and navigate through the results and even make small changes to primitive data and Strings. After playing with it for a while, here is a list of additional features I'd love to have: 1. Export of selected data: a. Simple - Select a range of cells or a column header and copy text to the clipboard or save to a file (csv, html, etc..). (There appear to be copy menu options, but I cannot get them to work.) ... way to do ad-hoc JPQL queries and navigate through the results and even make small changes to primitive data and Strings. ... 3. On the Query page, please add a checkbox to request the Results either as a table or tree. 4. It would be terrific if the ...

 
release

2.6.6

... in handling large objects with long primary keys as query results ( issue #260 ). Fixed detachment of embedded objects to ... Fixed a bug of returning managed hollow objects in query results. Fixed an error message for invalid DELETE query ( issue ...

 
manual

Logical Operators in JPQL and Criteria API

Explains how to use AND, OR and NOT in JPQL queries. Logical operators in JPQL and in JPA criteria queries enable composition of complex JPQL boolean expressions out of simple JPQL boolean expressions. This page covers the following topics: Logical Operators ...

 
api-jpa

javax.persistence.SqlResultSetMapping

Specifies the mapping of the result of a native SQL query.(Annotation of JPA)