Cursor PROBLEM [message #369822] |
Wed, 18 October 2000 19:09 |
Gerardo Rivera Bozon
Messages: 1 Registered: October 2000
|
Junior Member |
|
|
Hello.
I have a function FUN1(x INTEGER) that returns an INTEGER, and I need a procedure that could return both x and FUN1(x).
What i've done is (The exact question is embebed in the code):
CREATE OR REPLACE PACKAGE anyPackage IS
TYPE respRecord IS RECORD (
col1 INTEGER;
col2 INTEGER;
);
pRecord respRecord;
TYPE pCURSOR is REF CURSOR RETURN pRecord%TYPE;
PROCEDURE returnCursor(anyPackage.pCursor IN OUT respCursor);
END anyPackage;
CREATE OR REPLACE PACKAGE BODY anyPackage IS
PROCEDURE returnCursor(anyPackage.pCursor IN OUT respCursor) IS
BEGIN
-- *************************************
-- HERE IS SUPPOSED TO BE THE LINES THAT
-- FETCHES x and FUN1(x) INTO respCursor
-- IS THERE ANY WAY TO DO THAT???
-- *************************************
END returnCursor;
END anyPackage;
|
|
|