
September 10th, 2006, 09:36 AM
|
|
Registered User
|
|
Join Date: Sep 2006
Posts: 2
Time spent in forums: 15 m 17 sec
Reputation Power: 0
|
|
|
DB2 stored procedure and Cobol
I have a stored procedure with a main module say MAIN and a data access module DAM. I validate data in MAIN and call DAM. The DAM has DECLARE CURSOR and OPEN CURSOR statements in it. would like to do a fetch outside the DAM , but in the MAIN module. Whenever i issue a fetch it returns to me error sqlstate 34000 for invalid cursor name. I xpedite the stored procedure. The cursor is opened successfully in the DAM , but when tried to access from MAIN it doesn't find it. How can i do this ? I know about locators , but it wont help in this case. Is there a way to refer a cursor opened in a module and do a fetch from another module . How can it be referenced ?
|