Function returning table parameter [message #37631] |
Mon, 18 February 2002 06:03 |
K Rajesh
Messages: 6 Registered: February 2002
|
Junior Member |
|
|
Hi,
I have a function which return table variable
--- function floater return CID_TABLE IS
--CID_TABLE is
-- TYPE CID_Table IS TABLE OF number INDEX BY BINARY_INTEGER;
Who to display all the records in 'Select Query' return by this function.
--- select floater from dual
This is not working, is there any alternative to print all the records ?
Please advice
Thanks in advance
Atul
|
|
|
Re: Function returning table parameter [message #37633 is a reply to message #37631] |
Mon, 18 February 2002 06:13 |
pratap kumar tripathy
Messages: 660 Registered: January 2002
|
Senior Member |
|
|
here is the example
--------------------
declare
TYPE CID_Table IS TABLE OF number INDEX BY BINARY_INTEGER;
abc cid_table;
begin
abc:=floater; /* call the function*/
for i in 1..abc.count /* loop through the array*/
loop
dbms_output.put_line(abc(i));
end loop;
end;
|
|
|