File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hibernate Err:NonUniqueObjectException

 
Abiodun Adisa
Ranch Hand
Posts: 495
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using Hiberante to save data to my Database , I am trying to save two objects having the same values into the database, that is i don't mind having duplicates, any time i run the code below


and the exception i am getting is



any Suggestion would be welcome
 
Abiodun Adisa
Ranch Hand
Posts: 495
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was able to resolve this by calling clear on the session after each save

getSession().clear
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic