Re: locking in 5.1 SE.
Posted in 1995
In article <4bgnl8$ic7@cssun.mathcs.emory.edu>, suresh@psi.ernet.in says... > >The process I have adopted for locking is : >DECLARE CURSOR FOR UPDATE; >OPEN CURSOR; >FETCH CURSOR; > >But, while I Fetch the next row, Lock on the existing row is removed. >Is there any other way to lock the rows in such a way that lock is retained >until COMMIT or ROLLBACK? Assuming that the whole thing is inside your transaction, setting your isolation to REPEATABLE READ will lock every row read until COMMIT or ROLLBACK. Just make sure that you're using an indexed read, though, or you will end up locking a whole lot of rows you didn't want to lock. June ---- June Tong Informix Software ---- ---- Senior Consultant (415) 926-6140 ---- ---- International Support junet@informix.com ----