A fix is available
APAR status
Closed as program error.
Error description
SQLCODE199 from DSNHPARS is reported in error when the length of an embedded SQL statement in a C/C++ application is more than 32767 and there is a question mark in a string in the statement. An "embedded SQL statement in C/C++ application" can also be an SQL statement in an external SQL PL stored procedure.
Local fix
Problem summary
**************************************************************** * USERS AFFECTED: Users of an external SQL PL stored procedure * * or a C/C++ application that contains a large * * SQL statement with a question mark (?) or * * back slash (\) inside a literal string with * * DB2 for z/OS Version 9.1 or 10.1. * **************************************************************** * PROBLEM DESCRIPTION: DB2 may incorrectly issue SQLCODE -199 * * or -104 during the bind of a large SQL * * statement from an external SQL PL * * stored procedure or a C/C++ * * application when the SQL statement has * * a string containg a question mark (?) * * or a back slash (\) and one of these * * two characters is beyond the position * * 32767 in the SQL statement. * **************************************************************** * RECOMMENDATION: * **************************************************************** The following example may expose the problem: EXEC SQL DECLARE CURSOR1 CURSOR WITH RETURN FOR SELECT 1 AS C1, 2 AS C2, ...... UNION SELECT 1000 AS C1000, 1001 AS C1001, ' /Reports/frmSchool.aspx?type=school' AS C1002 FROM T1000; The above SQL statement is embedded in a C application and the position of the literal string is beyond 32767 in the SQL statement. Additional keywords: SQLCODE199 SQLCODE104 SQLEXTERNALSQLPL SQLSP SQLSTOREDPROC
Problem conclusion
DB2 for z/OS code is changed so that the invalid error is no longer reported.
Temporary fix
Comments
APAR Information
APAR number
PM84539
Reported component name
DB2 OS/390 & Z/
Reported component ID
5740XYR00
Reported release
A10
Status
CLOSED PER
PE
NoPE
HIPER
NoHIPER
Special Attention
NoSpecatt
Submitted date
2013-03-11
Closed date
2013-04-08
Last modified date
2013-05-03
APAR is sysrouted FROM one or more of the following:
APAR is sysrouted TO one or more of the following:
UK93224 UK93225
Modules/Macros
DSNHTOKR
Fix information
Fixed component name
DB2 OS/390 & Z/
Fixed component ID
5740XYR00
Applicable component levels
Fix is available
Select the PTF appropriate for your component level. You will be required to sign in. Distribution on physical media is not available in all countries.
[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSEPEK","label":"Db2 for z\/OS"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"10.1","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}},{"Business Unit":{"code":"BU054","label":"Systems w\/TPS"},"Product":{"code":"SG19M","label":"APARs - z\/OS environment"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"10.1","Edition":"","Line of Business":{"code":"","label":""}}]
Document Information
Modified date:
03 May 2013