This content has been marked as final.
Show 2 replies
-
1. Re: What causes EntityExistsException?
epbernard Dec 18, 2006 1:32 PM (in response to vk101)if the entity is already persistent in the PC, calling persist() will raise EPE
-
2. Re: What causes EntityExistsException?
vk101 Dec 18, 2006 6:57 PM (in response to vk101)What qualifies as being "already persistent"?
Does that mean an entity whose equals() test returns true, or does it look at the @Entity definition at the Id and/or @Column(unique=true) fields only?
Also, does it drill down to the actual database layer at insertion time for tables with unique constraints but no corresponding annotation defined on the entity? Or does that come back as a different kind of error?
I haven't seen this documented anywhere, so I'm wondering...
Thanks.