About TypedQuery

131-140 of 143Refresh
Issue
1

query.getResultList() throws ClassCastException

I modified the example code to include an index on the Point class like so:     @Index(members={"x","y"}) Then when I run the following query:     TypedQuery query = em.createQuery("SELECT p FROM Point p where p.x <= :x and p.y >= :y",         Point.class); I get the exception at the end.  I
Forum
1

Restrict by class in query

I have the following bit of code: public List findFolderByName(String folderName) { TypedQuery byNameQuery = this.entityManager.createQuery("SELECT f FROM Entry f WHERE f.name=:name", Folder.class); return byNameQuery.setParameter("name", folderName).getResultList(); } I
Forum
1

Schema-Update: Rename superclass and remove one subclass

we get the described error message.   If we try to ecexute a Query (in the second main method): TypedQuery
Issue
1

Schema-Update: Rename superclass and remove one subclass

we get the described error message.   If we try to ecexute a Query (in the second main method): TypedQuery
Forum
1

Sorting problem

;     TypedQuery icQuery = null;     String q = null;     q = "select br from Branch br ORDER
Forum
1

Subquery error

My query: TypedQuery query = em.createQuery("SELECT p FROM Station p WHERE rid = (SELECT p FROM Station p where tpl='York') AND tpl != 'York'", Station.class);   Error: Exception in thread "main" [ObjectDB 2.6.6_04] SELECT p FROM Station p WHERE rid = ( ==> SELECT <==  p FROM
Issue
1

Super class' field access fails

() { return decrease; } } Now, when issuing the following query: TypedQuery query
Forum
1

Why the internal error was thrown?

) {     EntityManager em = getEntityManager();     TypedQuery q = em.createQuery(query, clazz);     q.setHint
Issue
1

Null pointer exception being thrown from within ObjectDB.

))               )             ).             orderBy(cb.desc(r.get("objectDbId")));     TypedQuery query
Forum
1

JPA - ExceptionInInitializerError when creating EntityManager

.EntityManagerFactoryImpl@ffa7e1 EntityManager emTemp = emf.createEntityManager(); TypedQuery