-Platform: iSeries V5r4
-Language: RPG IV (using \free syntax)
Here is what i am trying to do:
The first RPG program declares and opens up a SQL cursor by means of "exec" statements. It will then call the second RPG program. The second program will try to access the SQL cursor that was opened by the first program.
According to IBM's website there is an option you can choose "*ENDSQL" and "*ENDJOB" for the parameter "CLOSQLCSR" that will keep SQL cursors open.
Question: How can I get the called program to use the SQL cursor that should already exist in memory?