Re: How to PERSIST object without loading references?

2008-06-12 Thread Anonimus
I've solved my problem by replaceing em.persist(e); with e = (Employee) em.merge(e); It works now. -- View this message in context: http://www.nabble.com/How-to-PERSIST-object-without-loading-references--tp16472647p17803850.html Sent from the OpenJPA Users mailing list archive at Nabble.com

Re: How to PERSIST object without loading references?

2008-06-11 Thread Anonimus
"[EMAIL PROTECTED]" in persistent field > "mypackage.Employee.idDepartment" of managed object > "mypackage.Employee-5" during flush. However, this field does not allow > to be CascadeType.PERSIST. You cannot flush unmanaged objects. Michael Dick wrote: > > Hi Anonimus, > &

Re: How to PERSIST object without loading references?

2008-06-11 Thread Anonimus
Ognjen Blagojevic wrote: > > It must be a way to INSERT objects in the database without looking up > for all the references, but I am not able to find it. > My problem is similar as yours, with a single difference. I don't mind loading all the references because I need them in the program. Bu