View previous topic :: View next topic
|
Author |
Message |
Hari Kishan
New User
Joined: 06 Jul 2007 Posts: 2 Location: Hyderabad
|
|
|
|
Hi Could any one please help me in finding the reasons about
SQL Code -991???
I have compiled sub program subPGM2 and then main program named MainPGM, which is using DB2. After that we ran the main program and its giving SQL code -991 for one of the sub program named subPGM (which was called by mainprogram MainPGM). We have modified only subPGM2 not other sub programs.
For compiling we are using tool LIMA.
Main program : MainPGM
Modified sub program : subPGM2 (Static call)
Effected sub program : subPGM1 (Dynamic call) is called subPGM
(Static call and we are getting sqlcode -991 in this program)
Why this error is coming only for Sub program not for mainprogram??
What is the reason for getting -991????
Thanks in Advance. |
|
Back to top |
|
|
CICS Guy
Senior Member
Joined: 18 Jul 2007 Posts: 2146 Location: At my coffee table
|
|
|
|
Have you looked at the fine manual?
Quote: |
| -991 CALL ATTACH WAS UNABLE TO ESTABLISH AN IMPLICIT CONNECT OR OPEN TO
| DB2. RC1= rc1 RC2= rc2
| Explanation: Call attach attempted to perform an implicit connect and
| open as the result of an SQL statement. The connect or open failed with
| the returned values.
| System Action: The statement cannot be executed.
| Programmer Response: Verify that the application intended to use the call
| attachment facility (CAF) as the mechanism to connect to DB2. For stored
| procedures running in the WLM-established stored procedure address space
| the application must be link-edited with or dynamically allocate the RRS
| attachment language interface module (DSNRLI), not CAF. |
|
|
Back to top |
|
|
Hari Kishan
New User
Joined: 06 Jul 2007 Posts: 2 Location: Hyderabad
|
|
|
|
Hi,
We have modified only subPGM2 and we are getting sql code:-991 for other sub program subPGM.
I have already gone through the programmer response.But I don't know how to verify this?
So can you please help me in this issue?
Programmer Response: Verify that the application intended to use the call
| attachment facility (CAF) as the mechanism to connect to DB2. For stored procedures running in the WLM-established stored procedure address space the application must be link-edited with or dynamically allocate the RRS attachment language interface module (DSNRLI), not CAF.
Thanks. |
|
Back to top |
|
|
vijikesavan
Active User
Joined: 04 Oct 2006 Posts: 118 Location: NJ, USA
|
|
|
|
Well,
SQL -991 messge in manual shows something different. For me it turns out to be Link error.
I was breaking my head couple of days back and finally found tht the link libraries used in my compile JCL was not correct.
If you have endevor or changeman, try compiling your programs in them and use tht load module.
donot try to compile from a PDS JCL.
It solved my problem. Hope this helps.
Thanks,
Viji |
|
Back to top |
|
|
|