Caused by: org.hibernate.NonUniqueObjectException: a different object with the same identifier value was already associated with the session: [com.my.nma.pojo .Lob#com.my.nma.pojo.LobId@bf82a59]
This message is a little bit cryptic. We found what the issue was. We had duplicate records for the same data and that was causing it. Is there some way to tell hibernate to spit out more information like some of the attibutes which are the key so that we can exactly tell what is it. Right now we had to take lot of hops to actually find what the issue was and connect the dot with the error.
Unfortunately, Hibernate is not going to know the state of your database, whether you have bad duplicate data in there. It can only say hey, you are trying to attach a second object with the same Primary Key to an object I already have in the persistent state. (In first level cache)
There is no data yet in the database its still in the Transient form about to be inserted in the the database. What I'm talking about is lets say you have a array of objects which has keys on a member and suppose you have 2 records having the same ID is there any way in hibernate to spit which records are duplicate...
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads