Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> cursor problem
Hi, all
there is an application below:
declare
cursor c1 is
select id,phone_nbr,work_order_nbr,acct_nbr
from cw_tb
where work_order_nbr>=' ' and
acct_id>='A00001' and acct_id<='A09000';
r1 c1%rowtype;
begin
open c1;
loop
fetch c1 into r1
......
......(some DML)
......
here come the problem..
when I use cursor,ORACLE will lock the table in exclusive mode or share
mode??
( in this exam. the table cw_tb will be locked in shared or exclusive? )
P.S I tried divide this AP to three small range,and ran on three different clients one by one.
i.e client1 open cursor c1 and acc_id>='A00001' and acc_id<='A03000' and
client2 open cursor c1 and acc_id>='A03001' and acc_id<='A06000' and
client3 open cursor c1 and acc_id>='A06001' and acc_id<='A09000'
but I find that client2&client3 will wait until client1 finish and client3 will wait until client2 finish and client3 will run finally
best regards
Alvin 10/8/1998 Received on Thu Oct 08 1998 - 02:56:09 CDT
![]() |
![]() |