Internal Website Search

1-50 of 200 results

Running JPA Queries

- for use when exactly one result object is expected. Query. getResultList - for general use in any ... - for use when exactly one result object is expected. TypedQuery. getResultList - for general use in any ... (with getResultList ) The following query retrieves all the Country objects in the database. The query

StoredProcedureQuery.getResultList() - JPA Method

JPA Method in javax.persistence.StoredProcedureQuery List getResultList () Retrieve the list of results from the next result set. The provider will call execute on the query if needed. A REF_CURSOR result set, if any, will be retrieved in the order the REF_CURSOR parameter was registered

Query.getResultList() - JPA Method

JPA Method in javax.persistence.Query List getResultList () Execute a SELECT query and return the query results as an untyped List. Return: a list of the results Throws: IllegalStateException - if called for a Java Persistence query language UPDATE or DELETE statement QueryTimeoutException

TypedQuery.getResultList() - JPA Method

JPA Method in javax.persistence.TypedQuery List getResultList () Execute a SELECT query and return the query results as a typed List. Return: a list of the results Throws: IllegalStateException - if called for a Java Persistence query language UPDATE or DELETE statement QueryTimeoutException

SELECT clause (JPQL / Criteria API)

= em. createQuery ("SELECT c FROM Country c", Country.class); List results = query. getResultList ... c.name FROM Country AS c", String.class); List results = query. getResultList (); Only singular ... .name FROM Country AS c", Object[].class); List results = query. getResultList (); for (Object[] result

Setting and Tuning of JPA Queries

that may affect query execution if invoked before a query is run using getResultList or getSingleResult ... : List results = query. setFirstResult (pageIx * pageSize) . setMaxResults (pageSize) . getResultList (); These methods can be invoked in a single expression with getResultList since the setter methods

JPA Criteria API Queries

. createQuery (q); List results = query. getResultList (); Using the criteria API introduces some extra ... ", Country.class); List results = query. getResultList (); Because eventually both types of queries ... . getResultList (); The setParameter method takes a Parameter (or a ParameterExpression ) instance as

JPA Named Queries

. createNamedQuery ("Country.findAll", Country.class); List results = query. getResultList ... . createNamedQuery ("Country.findAll"); List results = query. getResultList (); One of the reasons

FROM clause (JPQL / Criteria API)

", Country.class); List results = query. getResultList (); for (Country c : results) {   

Posting Sample Code

. getResultList ();         System.out.println(resultList);   

NPE at com.objectdb.jpa.JpaQuery.getResultList

:1300) at com.objectdb.o.QRR.b(QRR.java:197) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery ... .setFirstResult(firstResult); } return q. getResultList (); } finally { em.close(); } } longpat Brian ... ;   return q. getResultList ();         }   

NPE on em.createQuery(query).getResultList()

(QRR.java:144) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:627) at org.tynamo.seedentity ... ). getResultList ();         em.getTransaction().commit();   

[ObjectDB 2.6.0_04] Unexpected exception (Error 990) com.objectdb.jpa.JpaQuery.getResultList

.objectdb.o.QRR.f(QRR.java:139) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:716) at com.btc

query.getResultList() throws ClassCastException

. getResultList (JpaQuery.java:665) at point.Main.main(Main.java:52) ryan.gustafson Ryan Gustafson

Another NPE on em.createQuery(query).getResultList()

) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:627) at org.tynamo.seedentity.jpa.services

javax.persistence.StoredProcedureQuery

have been defined by the stored procedure. When getResultList and getSingleResult are called ... processing getResultList or getSingleResult . When executeUpdate is called on a StoredProcedureQuery ... getResultList or getSingleResult . The hasMoreResults method can then be used to test for further results

Missing Data on Retrieval (0, null values)

). getResultList ();   exportToCSV(resultList); }   Best regards, Harald harald77 Harald ... .createQuery("SELECT p  FROM Person p"). getResultList ();     - resultlist1   OK List resultList2 = em.createQuery("SELECT d  FROM Document d" ). getResultList (); - resultlist2

java.lang.NullPointerException when using ORDER BY

.RecordingMetaDataDAO. getResultList (RecordingMetaDataDAO.java:925)          ... .services.RecordingService. getResultList (RecordingService.java:373)        ... ;   at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:695)     

Problem with distinct select, order by and equivalent alias/attribute path

, Location.class). getResultList ();               ... , Location.class). getResultList ();               ... , Location.class). getResultList ();             

Connection is closed (error 526)

(error 526) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:633) at fpg.Nodes.getSons(Nodes ... ) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:627) ... 3 more Caused by: java.io ... .objectdb.o.QRR.b(QRR.java:168) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:627) at fpg

EM close causes an exception

:1588) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:738) ... 54 more Caused by: java.lang ... . getResultList (JpaQuery.java:726) ... 69 more btc_es BTC EmbeddedSystems We had also some issues ... .JpaQuery. getResultList (JpaQuery.java:726) btc_es BTC EmbeddedSystems the previous version 2.8.7_04

Unexpected NoSuchFieldError exception

a no-arg constructor (error 352) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:728) at sun ... .objectdb.o.QRR.f(QRR.java:212) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:719) ... 47 ... .jpa.JpaQuery. getResultList (JpaQuery.java:728) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native

How to convert a boolean to an int in the query?

;    resultList = query. getResultList (); support Support Query  SELECT approveEmail ... .createQuery(q); resultList = query. getResultList (); works fine.   But criteria query CriteriaBuilder cb ... . getResultList (); does not work galandor Orlov Sergey Just tried a similar query on the world.odb

Calendar in Criteria Querys

;       List results = em.createQuery(query1). getResultList ();   ... ;    .setParameter(p, Calendar.getInstance()). getResultList ();     ... ) at com.objectdb.o.QRR.b(QRR.java:151) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:666

Strange behaviour with ORDER BY and IN

;          . getResultList ().forEach(l ... .toList()))             . getResultList ... ;    . getResultList ().forEach(l - System.out.println("Location: " + l));   

Exception when querying Map property with @embedded & Enhancer enabled

; for (MyEntity2 myEntity : em.createQuery("select e from MyEntity2 e", MyEntity2.class). getResultList ()) {   ... '", MyEntity2.class). getResultList ()) {    System.out.println(myEntity2);   } } @Entity ... .objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:725) at TestEmbeddableMap.main(TestEmbeddableMap

locks on pure query activities

(QRR.java:247) at com.objectdb.o.QRR.f(QRR.java:153) at com.objectdb.jpa.JpaQuery. getResultList ... .jpa.JpaQuery. getResultList (JpaQuery.java:719) - locked (a com.objectdb.jdo.PMImpl) at com.agile ... ) at com.objectdb.o.QRR.f(QRR.java:153) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:719

JPQL keyword in entity - what to do?

. getResultList (JpaQuery.java:571) ~[objectdb.jar:na] There is no problem with this query when I choose ... Product as p group by p.type.name", ResultData.class); List res = q. getResultList (); ResultData ... .JpaQuery. getResultList (JpaQuery.java:573) ~[objectdb.jar:na] It looks like ODB is trying to use setter

Step 4: Add a Servlet Class

of guests: List guestList = em.createQuery( "SELECT g FROM Guest g", Guest.class). getResultList

Step 3: Define an EJB Session Bean

); return query. getResultList (); } } The  GuestDao session bean (EJB) class defines two methods

Step 3: Define a Spring DAO Component

query. getResultList (); } } The GuestDao Spring component class defines two methods: persist

Step 3: Define a Spring DAO Component

query. getResultList (); } } The GuestDao Spring component class defines two methods: persist

Step 3: Define an EJB Session Bean

Guest g ORDER BY g.id", Guest.class); return query. getResultList (); } } The GuestDao session bean (EJB

Step 4: Add a Servlet Class

Guest g", Guest.class). getResultList (); request.setAttribute("guests", guestList); request

javax.persistence.Query

List getResultList () Execute a SELECT query and return the query results as an untyped List. Return ... results as an untyped java.util.stream.Stream . By default this method delegates to getResultList ... set and the transaction is rolled back See Also: Stream getResultList () Since: JPA 2.2 Object

javax.persistence.TypedQuery

when the implementation does not support this use Inherited from: Query Since: JPA 2.0 List getResultList () Execute ... .stream.Stream . By default this method delegates to getResultList ().stream() , however persistence ... back See Also: Stream getResultList () Since: JPA 2.2 X getSingleResult () Execute a SELECT query

Schema-Update: Rename superclass and remove one subclass

. getResultList (); System.out.println("size: " + result.size()); We get an exception: [2016-11-14 10:48:56 #1 ... . getResultList (JpaQuery.java:719) at schemaupdate.delete.UpdateDB.main(UpdateDB.java:32) Exception in thread ... ) at com.objectdb.o.QRR.f(QRR.java:212) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:719

Why the internal error was thrown?

:247) at com.objectdb.o.QRR.f(QRR.java:153) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java ... .objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:719) at com.btc.ep.base.dal.internal.services ... ("objectdb.result-fetch", "LAZY");     return q. getResultList (); } btc_es BTC

Distinct Error

.jar:na] at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:633) ~[objectdb-2.2.8.jar:na] at sun ... .jar:3.0.5.RELEASE] at $Proxy74. getResultList (Unknown Source) ~[na:na] at com.contextspace.dao.impl ... .JpaQuery. getResultList (JpaQuery.java:627) ~[objectdb-2.2.8.jar:na] ... 49 common frames omitted  

com.objectdb.o.InternalException: Unexpected internal exception

). getResultList (); I get the following exception: com.objectdb.o.InternalException: Unexpected internal ... .OBC.onObjectDBError(OBC.java:1556) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:728 ... :549) at com.objectdb.o.QRR.f(QRR.java:212) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java

Query.getResultStream() - JPA Method

to getResultList ().stream() , however persistence provider may choose to override this method to provide ... timeout value set and the transaction is rolled back See Also: Stream getResultList () Since: JPA 2.2

TypedQuery.getResultStream() - JPA Method

to getResultList ().stream() , however persistence provider may choose to override this method to provide ... timeout value set and the transaction is rolled back See Also: Stream getResultList () Since: JPA 2.2

javax.persistence.NamedQuery

= em.createNamedQuery("findAllCustomersWithName") .setParameter("custName", "Smith") . getResultList

Query fails with failed to read

when using a getResultList () on a query. there are not any logs in the log (we are using embedded ... (AbstractConnection.java:544) our JAVA code is:   ... try { List objectNodes = queryContainer. getResultList ... .objectdb.o.QRR.i(QRR.java:155) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:721) at com.agile

Unexpected exception (Error 990) com.objectdb.o.InternalException

) at com.objectdb.o.QRR.f(QRR.java:139) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:716 ... .JpaQuery. getResultList (JpaQuery.java:716) at com.btc.ep.dal.persist.impl.PersistenceService ... ) at com.objectdb.o.QRR.f(QRR.java:139) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:716

Inverse OneToMany Mapping and EmbeddedId

( " select a from A a " , A . class ) . getResultList ( ) ) ;          out . println ( em . createQuery ( " select b from B b " , B . class ) . getResultList ... . class ) . getResultList ( ) ;          out . println ( abs ) ;  

again merger missing logs + objectdb exception

) at com.objectdb.o.QRR.f(QRR.java:153) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:719 ... . getResultList (JpaQuery.java:719) at com.agile.hummingbird.CT_Container.computeContainer(CT_Container ... .JpaQuery. getResultList (JpaQuery.java:721) hgzwicker Hans-Georg Zwicker It seems that two separate issues

NullPointer on query

.setParameter("id", msg.getId()); List loaded = query. getResultList (); Stack trace follows: rbccm.felix ... .onObjectDBError(OBC.java:1493) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:695) at rbccm ... (QRR.java:151) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:686) ... 6 more The code

Issue with TYPE expression in Criteria API

persistable type java.lang.Class (error 303) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java ... :151) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:666) ... 2 more quasado Alexander Adam ... ). getResultList ();         System.out.println("Size: " + resultList.size

Unexpected Exception (Error 990) with ArrayIndexOutOfBoundsException

.i(QRR.java:225) at com.objectdb.jpa.JpaQuery. getResultList (JpaQuery.java:721) at backend ... happens here: final List results = query. getResultList ();) : private void only50000Rows(EntityManager ... ); query.setFirstResult(50000); final List results = query. getResultList (); final Query queryDelete = em .createQuery("DELETE FROM EventLogPersistEntry p WHERE p.id