Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

May I know what does this question asking?

 
Fei Wong
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I don't understand what does this question asking:

Under which two conditions can the developer expect the persistence provider to ensure that all changes made to the persistence context in the transaction are visible to the processing of the query?

I just don't understand the term "visible to the processing of the query".

Can anyone please explain to me?

Thank You very much
 
Logan Lee
Greenhorn
Posts: 18
Java Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think this question goes about the situation where you first perform operations on the entitymanger and then you use run a query (JPQL) that uses this data also in one transaction.

To rephrase: If you for example update an entity using the entitymanager and then you run a query that will display fields from that entity, how can you make sure the query reflects the changes you've done via the entity manager?

--> See the FlushModeType :
http://download.oracle.com/javaee/5/api/javax/persistence/FlushModeType.html

 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!