Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Optimistic Locking

 
Tony romer
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If a transaction rollbacks, does still version number changes?

I missed a question in UCertify, it was stating, version number changes if a transaction commits or rollbacks.
I was thinking it changes just only when transaction commits.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was thinking it changes just only when transaction commits.

You're right. It makes no sense to update the version number if the transaction rolls back. That would prevent other pending transactions to commit, although no changes have been made.
 
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
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!