posted 18 years ago
Hi,
Taking a look at JPA specification (3.2.1)
...persist operation, applied to an entity X are as follows:
...
If X is a removed entity, it becomes managed.
...
but when I try to run a simple hibernate example:
...
em.setFlushMode(FlushModeType.COMMIT);
Message m = em.find(Message.class, 32768L);
em.remove(m);
em.persist(m);
...
EntityNotFoundException: deleted entity passed to persist.
How can a removed entity becomes managed as a result of persist operation?? Am I missing something??
Please, any help?
Thanks.
[ December 10, 2006: Message edited by: Alexandre Lima ]