Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Oracle concurrence control
For some reason, I posted a followup to my own message but it didn't
appear. What I want to supplement is that, you can "artificially"
implement this concurrency control. You create a table called, say,
mutex with the column roomnum, personchecking, and timechecked. When A
checks and finds that the room is available through a select statement,
the database server also inserts the room number into mutext(roomnum),
'A' into personchecking and that moment of time into timechecked. Let's
say you set the expiration time for holding this room at 5 minutes.
Assuming A doesn't book the room within 5 minutes, when B comes in
within 5 minutes, he'll see roomnum is on hold; if after 5 minutes,
it's available and he can hold it...
<p>
You got the idea.
Yong Huang<br>
Email:yong321_at_yahoo.com
Web: http://www.stormloader.com/yonghuang/
![]() |
![]() |