Posts Tagged persist

Persist detached entity

Sometimes you have to store an object in a database. I run into the problem that I got this error: org.hibernate.PersistentObjectException: detached entity passed to persist It’s realy easy to solve this problem, just ensure to create the object to be saved after beginning the transaction. In my case I just created a constructor like [...]

, ,

No Comments