Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: Locking
Sure, just do
select null
from mytable
where <condition>
for update of <column_list>
It will lock rows on condition. Second part is tricky. Applications which are trying to lock immediate will fail with error, other applications will wait forever until lock is released. For example, second select for update with nowait option will fail, but direct update statement will wait. All ddl operations will fail too.
In article <974396521.621843_at_ernani.logica.co.uk>,
"Graham Atkinson" <g.a_at_totalise.co.uk> wrote:
> Is it possible within Oracle to lock a single record on a table so
that any
> application attempting to update that record would get an error retruned.
> This lock needs to be present even if the database has been shutdown and
> restarted (although I could use a DBMS_JOB to kick the lock off again)
>
> Thanks,
>
> Graham.
>
>
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Thu Nov 16 2000 - 12:19:53 CST
![]() |
![]() |