howto return reference cursor that also updates
10626Mar 29 2005 — edited Mar 21 2006Hi,
I have a stored function that returns a reference cursor. The reference cursor query contains a field that is used as a flag to select on:
type refCursor is ref cursor;
function fname( ) return refCursor
is
begin
open my_cursor for
select ...
from table1, table2, ...
where table1.flag = 0 and ...;
return my_cursor;
end;
I would like to know if there is a way to set the table1.flag field to 1 in each record within the result set after the cursor has been closed or at the cursor poition while it is being read from? And if so, how to accomplish this.
Thanks,
David