About FROM



Used to construct criteria queries, compound selections, expressions, predicates, orderings.(Interface of JPA)



Explains how to apply server side bulk delete using a JPA/JPQL query.... chapter 2 , entity objects can be deleted from the database by: Retrieving the entity objects into an EntityManager . Removing these objects from the EntityManager  within an active transaction, either ... SELECT queries, which are used to retrieve data from the database, DELETE queries do not retrieve data from the database, but ...



Insert/update entity data into cache when read from database and when committed into database: this is the default behavior.(Enum Constant of javax.persistence.CacheStoreMode)


Missing Data on Retrieval (0, null values)

I try  to export all Objects in an Flatfile-Hiearchy (.csv). But only the first exported Table contains all necessary Data. Most of the others  contains all  Object-Rows', but most Values of the Columns are missing. With a  em.clear() inside the Loop, all tables are exported correctly but the Enity-Keys do not match. I can't get the point - what am i doing wrong?   emf = Persistence.createEntityManagerFactory(dbFile); em = emf.createEntityManager(); ... resultList = em.createQuery("SELECT q  FROM "+tableName+" "+n).getResultList();   exportToCSV(resultList); ... resultList1 = em.createQuery("SELECT p  FROM Person p").getResultList();     -> resultlist1   OK ... resultList2 = em.createQuery("SELECT d  FROM Document d" ).getResultList(); -> resultlist2  Bad - many null ...



Refresh the state of the instance from the database, overwriting changes made to the entity, if any.(Method of javax.persistence.EntityManager)


JPA Query language support in OBjectDB / Sub query or nested Query

Hi Wanted to check with you on the exact level of support of JPA QL within the ObjectDB world. I have given a sample typed query below which fails to work with ObjectDB and it runs very well with the Hibernate/MySQL JPA. We are using Spring Data here. It looks like a problem with Sub query or nested queries where I am using IN clause like below. ... IN clause like below. @Query("SELECT product FROM Product product WHERE product.id in (SELECT msg.objectId FROM Message msg WHERE msg.contextId = :contextIdParam)") ...


Query problem after transaction commit

I have a machine running the objectdb server and the client on another machine connect to it. The client program can connect to the server and query to get all the records. However, after transaction.begin ... persist(p) .. commit of a new object, my client program can no longer retrieve the old records but only the latest stored record. I tried to run database explorer on the server machine and able to see all the records including the new stored record.... issue with a simple solution (e.g. changing flush mode from commit to auto could solve it). However, a situation in which you can ... for all object Goods successfully] 04> SELECT u FROM Goods u where u._code like :code AND u._desc like :desc  05> ...


Object DB vs EclipseLink/TopLink: Unloaded relationships in detached entities

This topic is for those considering migrating from EclipseLink JPA or TopLink to ObjectDB JPA. ... This topic is for those considering migrating from EclipseLink JPA or TopLink to ObjectDB JPA. This concerns a huge "gotcha" that other assessing migrating from and EclipseLink-based JavaEE web application to ObjectDB may encounter, ...



Read entity data from the cache: this is the default behavior.(Enum Constant of javax.persistence.CacheRetrieveMode)



Insert/update entity data into cache when read from database and when committed into database.(Enum Constant of javax.persistence.CacheStoreMode)