Re: How to PERSIST object without loading references?

2008-08-20 Thread Edmond M.
-to-PERSIST-object-without-loading-references--tp210631p735154.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
this message in context: http://www.nabble.com/How-to-PERSIST-object-without-loading-references--tp16472647p17778155.html Sent from the OpenJPA Users mailing list archive at Nabble.com.

Re: How to PERSIST object without loading references?

2008-06-11 Thread Enrico Goosen
= cascadeType.PERSIST, I get an exception (as you do). If I don't put cascade = cascadeType.PERSIST (which is logical), I get an exception. Since I'm new in JPA, I'm quite lost now. -- View this message in context: http://www.nabble.com/How-to-PERSIST-object-without-loading-references

Re: How to PERSIST object without loading references?

2008-06-11 Thread Fay Wang
PROTECTED] wrote: From: Enrico Goosen [EMAIL PROTECTED] Subject: Re: How to PERSIST object without loading references? To: users@openjpa.apache.org Date: Wednesday, June 11, 2008, 11:44 AM I'm getting so frustrated with OpenJPA! I'm also experiencing the problem listed in previous reply

Re: How to PERSIST object without loading references?

2008-06-11 Thread Anonimus
cascade = cascadeType.PERSIST, I get an exception (as you do). If I don't put cascade = cascadeType.PERSIST (which is logical), I get an exception. Since I'm new in JPA, I'm quite lost now. -- View this message in context: http://www.nabble.com/How-to-PERSIST-object-without-loading-references

Re: How to PERSIST object without loading references?

2008-04-04 Thread Ognjen Blagojevic
It is, indeed. Thanks. Now I really understand why did the specification declared both find and getReference. O:) Regards, Ognjen Patrick Linskey wrote: Hi, EntityManager.getReference() is your friend here. -Patrick On Thu, Apr 3, 2008 at 4:19 AM, Ognjen Blagojevic [EMAIL PROTECTED]

How to PERSIST object without loading references?

2008-04-03 Thread Ognjen Blagojevic
Hi all, Is there a way to persist an Entity without loading all the referenced objects? I know that this is possible: Employee e = new Employe(); e.setName(John Doe); e.setIdDepartment(findDepartmentByPrimaryKey(idDept)); e.setIdRank(findRankByPrimaryKey(idRank)); // and so on em.persist(e);

Re: How to PERSIST object without loading references?

2008-04-03 Thread Patrick Linskey
Hi, EntityManager.getReference() is your friend here. -Patrick On Thu, Apr 3, 2008 at 4:19 AM, Ognjen Blagojevic [EMAIL PROTECTED] wrote: Hi all, Is there a way to persist an Entity without loading all the referenced objects? I know that this is possible: Employee e = new Employe();