Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Locking question

Re: Locking question

From: <MTPConsulting_at_aol.com>
Date: Fri, 13 Oct 2000 23:13:23 EDT
Message-Id: <10648.119240@fatcity.com>


John,
Do a SELECT ... FOR UPDATE NOWAIT on the row first. If the row is locked, you will return to your program right away. Then, you can do a timed wait and try again as many times as you want.

Marc Perkowitz
MTP Systems Consulting

In a message dated 10/13/00 6:44:15 PM Central Daylight Time, johnm9563_at_netscape.net writes:

<< HI all:  

 Is there an easy solution to this :  

 I have one process that has not committed and is holding a lock on a record.  Process #2 wants to update the same record. Is there any way to tell process
 #2 to only wait X amount of time before returning an error or have the error  returned immedialty? In other words if the record is locked, I do not want  process #2 to wait until it is unlocked, I want to tell it how long to wait,  then give me an error. Received on Fri Oct 13 2000 - 22:13:23 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US