This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hibernate save or update is not working fine

 
Mohan Ramu
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have problem to utilize saveOrUpdate() method,

i have table user which is having columns name, address and id which is generated by hibernate Auto.

i wanna save first

(Mohan, BTM) == in DB (1, Mohan, BTM) it's working fine

i wanna update the same record in DB(1, Mohan, EC).

Instead of saving like this save or update method is creating one more row like

2 , mohan, EC.

please clarify my doubt .


 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic