This content has been marked as final.
Show 6 replies
-
1. Re: Manual flush not working
kimlord Sep 15, 2007 9:05 AM (in response to kimlord)This is being called from an EitityHome class created using the Seam generate-entities.
-
2. Re: Manual flush not working
pmuir Sep 15, 2007 6:59 PM (in response to kimlord)Mark the persist method @Transactional for a start.
-
3. Re: Manual flush not working
kimlord Sep 15, 2007 8:50 PM (in response to kimlord)I did try that and it didn't make a difference.
-
4. Re: Manual flush not working
kimlord Sep 15, 2007 8:51 PM (in response to kimlord)The database is Oracle. Does that make a difference?
-
5. Re: Manual flush not working
kimlord Sep 15, 2007 8:55 PM (in response to kimlord)This was my last try:
@In EntityManager entityManager; @Transactional @Begin(flushMode=FlushModeType.MANUAL, join=true) public String persist() { log.info("Override persist"); getEntityManager().joinTransaction(); getEntityManager().persist( getInstance() ); getEntityManager().getTransaction().commit(); getEntityManager().flush(); moveTempRecord(); return "success"; }
I have spent all day on this with no luck. I am new to seam so any help is greatly appreciated.
Kim -
6. Re: Manual flush not working
fhh Sep 16, 2007 4:26 AM (in response to kimlord)AFAIK flush() sends the data to the database but does not commit the transaction. So depending on your transaction isolation level you may not be able to see the new records in another transaction.
Regards
Felix