home clear 64x64
en blue 200x116 de orange 200x116 info letter User
suche 36x36
Latest versionsfixlist
11.1.0.7 FixList
10.5.0.9 FixList
10.1.0.6 FixList
9.8.0.5 FixList
9.7.0.11 FixList
9.5.0.10 FixList
9.1.0.12 FixList
Have problems? - contact us.
Register for free anmeldung-x26
Contact form kontakt-x26

DB2 - Problem description

Problem IC88341 Status: Closed

CALLING STORED PROCEDURE ON NON-LUW DATABASES FAILS TO RETURN THE RETURN
CODE WRITTEN IN THE STORED PROC

product:
DB2 FOR LUW / DB2FORLUW / A10 - DB2
Problem description:
When calling a stored procedure located on a non 
Linux/Unix/Windows database 
server such as z/OS and i-Series the return code inside the 
stored procedure is not returned. 
 
The output below should return "RETURN STATUS: 1000" since this 
was coded in the stored procedure.  Instead the incorrect output 
"RETURN STATUS: 0" is returned. 
 
 
connect to sample user db2inst1 using 
 
   Database Connection Information 
 
 Database server        = DB2 z/OS 9.1.5 
 SQL authorization ID   = DB2INST1 
 Local database alias   = SAMPLE 
 
 
CREATE PROCEDURE TEST (OUT ID INTEGER) RESULT SETS 1 
        LANGUAGE SQL 
        DISABLE DEBUG MODE 
P1: BEGIN 
 
        DECLARE cursor1 CURSOR WITH RETURN FOR SELECT c1 from 
t1; 
        -- If OPEN cursor1 is commented out the expected rc=1000 
is returned 
        OPEN cursor1; 
        RETURN 1000; 
END P1 
DB20000I  The SQL command completed successfully. 
 
call test(?) 
ID: NULL 
 
C1 
 
 "TEST" RETURN_STATUS: 0
Problem Summary:
**************************************************************** 
* USERS AFFECTED:                                              * 
* ALL                                                          * 
**************************************************************** 
* PROBLEM DESCRIPTION:                                         * 
* See Error Description.                                       * 
**************************************************************** 
* RECOMMENDATION:                                              * 
* Upgrade to DB2 V10.1 Fix Pack 2 or higher.                   * 
****************************************************************
Local Fix:
available fix packs:
DB2 Version 10.1 Fix Pack 2 for Linux, UNIX, and Windows
DB2 Version 10.1 Fix Pack 3 for Linux, UNIX, and Windows
DB2 Version 10.1 Fix Pack 4 for Linux, UNIX, and Windows
DB2 Version 10.1 Fix Pack 3a for Linux, UNIX, and Windows
DB2 Version 10.1 Fix Pack 6 for Linux, UNIX, and Windows

Solution
Problem first fixed in DB2 V10.1 Fix Pack 2.  This should be 
applied to the DB2 Connect system used to establish 
connectivity to non Linux/Unix/Windows database servers such as 
z-Series and i-Series.
Workaround
not known / see Local fix
Timestamps
Date  - problem reported    :
Date  - problem closed      :
Date  - last modified       :
17.11.2012
19.04.2013
19.04.2013
Problem solved at the following versions (IBM BugInfos)
Problem solved according to the fixlist(s) of the following version(s)
10.1.0.2 FixList
10.5.0.2 FixList