On Fri, 17 Jan 2003, Jon Swinth wrote:
> Oracle's behavior AFAIK depends on which lock you are talking about. If you
> are talking about not being able to get a read lock then Oracle just blocks
> until it can, indefinately unless a deadlock is detected.
>
> If you are talking about a write lock, that depends on how the write lock is
> called. If you call SELECT ... FOR UPDATE or call UPDATE/DELETE without
> locking first then again Oracle will block until it can get the lock. If you
> call SELECT ... FOR UPDATE NOWAIT then Oracle will throw a specific SQL
> exception if a lock cannot be granted immediately. This allows you to do a
> sleep and retry in your code so that you only wait for a lock so long:
I was wondering about the NOWAIT specific behavior particularly. You
could send a notice (completion condition) I guess, but an actual
exception wouldn't work.