DBMS_OUTPUT in a for update cursor.. [message #8318] |
Fri, 08 August 2003 13:45 |
Meenakshi
Messages: 28 Registered: December 2001
|
Junior Member |
|
|
Hi,
This is my code:
DECLARE
current_bldg_code varchar2(30) := 'LIB' ;
CURSOR upd_capacity_cursor is select room, capacity from location where bldg_code='LIB'
FOR UPDATE of CAPACITY;
capacity_row upd_capacity_cursor%ROWTYPE;
BEGIN
FOR capcity_row IN upd_capacity_cursor
LOOP
update location set capacity=200 where CURRENT OF upd_capacity_cursor;
DBMS_OUTPUT.PUT_LINE ('The value of capacity is '|| capacity_row.capacity);
END LOOP;
END;
/
It gives the following display:
The value of capacity is
The value of capacity is
PL/SQL procedure successfully completed.
It doesn't display the value 200 here. Could anyone tell me how to fix this code?
Thanks.
|
|
|
|
|