Home » Search

About query

181-190 of 200Refresh
Forum
10

Duplicate Entity class names causes Exception in Query

of one of these entities. If I execute that query I get an exception;   Caused by: com.objectdb.o ... ) ... 64 more Here is the class doing the query on objdbTest.Item package objdbTest; import .... @Entity @NamedQueries({ @NamedQuery(name = "objdbTest.Singleton.getItem", query = "SELECT o
Forum
10

Unable to execute update query

Hello! I'm trying to do an update query via the explorer to set a new field value for around 400k ... file that is used in an update query, but the cause is unclear, and according to your report ... javax.persistence.Query; public class T1803 {     public static void main(String[] args
Forum
10

Calendar in Criteria Querys

Hi, i am having troubles creating criteria querys for Calendar objects. As far as I ... got such methods, but i dont know how to use those in my query. JPA supports 3 temporal types: java ... . Anyway, the following example demonstrates criteria queries with Calendar. The usual comparison methods
Forum
10

Criteria Query results in a NoResultException instead of returning object

(criteria).getSingleResult(); which evaluates to the query: SELECT $1 FROM IdentityObject $1 ... ._NoResultException: No matching results for a unique query at org.jboss.seam.security.IdentityImpl ... ) Caused by: com.objectdb.o._NoResultException: No matching results for a unique query at com.objectdb.o
Issue
10

Different behavior for two equal queries

Hi, I've got two equal queries though they behave differently: SELECT FROM com.quasado.foundation ... no results... Alex Here're also the execution plans from the explorer if that helps: First query (which works): Query Plan Description ====================== Step 1: Process IndividualContact ($1
Forum
10

Entity has be persistended,but query not fetched?

I create a new entity T newT and persistend it,then I create a query "select t from T t" to fetch all T entities.But  then the newT is not contain in the query result. Why? code order: query.setFlushMode(FlushModeType.AUTO); query.getResultList();   The following example demonstrates
Forum
10

Is named-query supported in orm.xml

I prefer to keep custom JPQL named queries in an external file, e.g. orm.xml, rather than in the entity classes, for example: query name= "DataValue.deleteByCapabilityAndCreationtime"> <query>delete from DataValue d where d.capabilityId = :capabilityId
Forum
10

Debuging query before execution

Hi, Is is possible in any way to get string representation of a query right before execution, after setting parameters? Of course it's easy to print out query string when we build it by concatenating ... do you suggest? The query string with parameter values embedded, replacing the parameter names? I think
Forum
10

Efficient query on EmbeddedId

understand that making a query just on entity.id.field1 is efficient. Of course, making a query ... is: what about making a query just on entity.id.field2? I suppose it will not be an efficient query ... indexed. Accordingly queries on field1 (and on both fields) will be fast, and queries on field2
Issue
10

NullPointer on query

> query = em.createQuery("SELECT m FROM ObjectDbMessagePayload m WHERE m.id = :id", ObjectDbMessagePayload.class); query.setParameter("id", msg.getId()); List loaded = query ... well (see below). Interestingly the exception is thrown from the find method rather than the query. The application