users@glassfish.java.net

Re: JPA merge creating new record

From: <glassfish_at_javadesktop.org>
Date: Fri, 06 Jul 2007 10:56:35 PDT

Is the insertion of the new row successful? If it is then the object that is passed to the merge call does not have a ID populated or has a new ID different from the object you expect to merge into. Note that the ID field used by TopLink is the one defined by the @ID annotation. Would it be possible for you to post the source to the entity involved in your simple test? Perhaps the test itself?

Is the row insertion failing because of a Unique Constraint violation?
--Gordon
[Message sent by forum member 'gyorke' (gyorke)]

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