• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hibernate Error:different object with the same identifier value was already associated with session

 
Ranch Hand
Posts: 44
Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

We tried to simulate the hibernate error in DEV and QA environments, but no luck. If I didn't re-produce the problem in DEV and QA, there is no point of 'fix' in production.

Here is the error message: ERROR webServiceMessageCall - "nested exception is org.hibernate.NonUniqueObjectException: a different object with the same identifier value was already associated with the session:"

I found some fixes by googling, but these are not helpful in re-producing the Hibernate error in DEV/QA environment.

Here is the simple hbm file:

** The AccKey is a simple bean.
Java code causing error:

Much appreciate your help in re-generating this problem in DEV.
 
Bartender
Posts: 10336
Hibernate Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It looks like your list of objects contains two entries that equate to the same thing. Can you post your key implementation code?
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic