users@glassfish.java.net

Re: Unique Constraint Question

From: <glassfish_at_javadesktop.org>
Date: Tue, 04 Sep 2007 12:46:19 PDT

Yes, I would think that running a query is your best solution - em.flush will throw PersistenceException that will cause transaction to be rolled back (see spec 3.7 Summary of Exceptions), unless this is what you want.

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

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