| IBM MAINFRAME HELP & SUPPORT FORUMS Technical Forums for IBM Mainframe Applications like COBOL, JCL, CICS, DB2, FileAid, DFSORT, Endevor, Xpediter, CoolGen, CA-7&11, AbendAid, IMS, IDMS, PL/I, MqSeries, SyncSort, Assembler, ChangeMan, Easytrieve, InterTest, REXX, CLIST etc...
|
| View previous topic :: View next topic |
| Author |
Message |
David Joyce
Joined: 08 Aug 2008
Posts: 5
Location: Boulder Colorado
|
| Posted: Sat Aug 09, 2008 1:41 am Post subject: Cobol/DB2 program calling REXX |
|
|
I have a Cobol/DB2 program which calls a REXX program. This part of the process works fine. I encounter an error(-924, SQLSTATE 58006, reason-code 00F30049) when the REXX attempts to attach to the DB2 subsystem(Address DSNREXX "CONNECT" DBST). The reason-code states "A request was received to connect the requester's TCB to a DB2 subsystem, but the TCB is already connected."
So my next step was to comment out the CONNECT since the TCB was already connected. The next SQL statement is the DECLARE of the cursor which works fine but when the program tries to PREPARE the SQL statement I get an error(-981, SQLSTATE 57015, reason-code 00C12219).
This error refers to RRSAF not being in a proper state and not having executed a CREATE THREAD in the REXX prior to trying to execute the PREPARE. I am not quite sure where to go from here, how do I perform the CREATE THREAD so the RRSAF facility is in the proper state so I can execute SQL statements in my REXX?
Thanks for any help. |
|
| Back to top |
|
| |
THIS IS AN ARCIVE FORUM IN READ ONLY MODE. IF YOU WANT TO ASK YOUR DOUBTS USE THE ACTUAL FORUM
|