create or replace procedure pro_t1
IS
cursor cur_t1 IS
select * from t1 where col2='aa';
begin
for get_cur_t1 in cur_t1 loop
if get_cur_t1=='aa' then
update t1 set col1:='xx';
elsif
update t1 set aa:=aa||1;
end if;
end loop;
end;
/
create function test(
al in varchar2)
return number
as
v_temp varchar2(100)
begin
while 1<>2
loop
begin
select column into v_temp from table where column = al;
exception
when NO_DATA_FOUND
then
return 1;
end;
update table set column = XX;
al := al + 1;
end;