Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Pipelined table and Ref Cursor
harry.ramp_at_hotmail.co.uk schrieb:
> procedure GetObjects (id in number, lref_cursor out refCursor)
> is
> localCursor refCursor;
> begin
> OPEN localCursor FOR
> SELECT * from TABLE(vendorschema.vendorfunction(id));
> lref_cursor:=localCursor;
> end GetObjects;
Why do you use a procedure for this?
You can directly query the pipelined table function like a table.
> Is there a way to get this running? Or do I have to find another method
> of returning table data to .Net?
Just use the DataAdapter to make this query: "select * from table(vendorschema.vendorfunction(:1))". Then bind whatever id you want to look for as ":1" and there you are. No need for a ref cursor here, me thinks.
hth,
Moritz Received on Wed Apr 19 2006 - 10:46:59 CDT