users@glassfish.java.net

Re: persist() and merge() and queries: what affects persistence context?

From: <glassfish_at_javadesktop.org>
Date: Tue, 17 Jun 2008 10:44:03 PDT

There are 3 options - use extended persistence context with a SFSB (but you'll also keep all other entities around; call em.find() to check if the entity is there in the database; always call em.merge() - it's allowed to be called on a new entity.

Regards,
-marina
[Message sent by forum member 'mvatkina' (mvatkina)]

http://forums.java.net/jive/thread.jspa?messageID=280792