Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

question about multi user work on record

 
Rajni Patel
Ranch Hand
Posts: 85
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have customer table. In that table, I want to update some field which are null or invalid.
for ex. in Customer table, I have 1000 record. In GUI, I have next, previous and update button.
If more than one user will work to update that record, How it will work.

Is it possible, if first user open 1st record then 2nd user open 2nd record and then again 1st user open 3rd record. means same record don't open with different user.

How it works?

If I write simple select and simple update then I know, update statement handling locking system. but in this scinerio more then one user can open same record with simple select.

Please, any body can guide me.
Thanks,
 
Jan Cumps
Bartender
Posts: 2608
14
C++ Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are two locking control mechanisms, called optimistic and pessimistic locking.
http://en.wikipedia.org/wiki/Concurrency_control
 
Jason Cone
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Exactly how such a scenario plays out depends on the isolation level of the transaction. You can set various isolation levels, but only to values that are supported by your database engine (and JDBC driver).

Check out this page on using transactions for more details about the available isolation levels and how to set them.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic