General information
Title:
Returning Result sets as a cursor ? from Oracle
HI!
I am trying seom test but can't seem to accomplish 1 thing...
Maybe someone can help.
To set it up you need Oracle and VFP 6.0
Here is the oracle code:
create or replace package types
as
type cursortype is ref cursor;
end;
/
create or replace function sp_listemp return types.cursortype
as
l_cursor types.cursortype;
begin
open l_cursor for select recno,mainkey from modacad order by recno;
return l_cursor;
end;
/
Note replace "select recno,mainkey from modacad order by recno"
with your SQL Statement:
Executing the following SQL Plus code works as I want it to...
************
variable c refcursor
exec :c :=sp_listemp
print c
But the question is how do I call this function from foxpro....
I tried
SQlExec( h, "{call sp_listemp(?@OutParam)}" )
SQlExec( h, "{call sp_listemp()}" )
But nothing works...
At one point I got a message something like cannot return
cursor result sets or something but I can't remember what I did.
Anyone got any ideas????
Maybe I need to use ADO RS's?
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only