DB2 - Problembeschreibung
Problem IC76229 | Status: Geschlossen |
SQL0104N RETURNED DUE TO SINGLE OR DOUBLE QUOTES INSIDE NEW STYLE COMMENT | |
Produkt: | |
DB2 FOR LUW / DB2FORLUW / 950 - DB2 | |
Problembeschreibung: | |
Another symptom is that users executing ALTER PROCEDURE will have the Line Feed (0xA) character removed before the DDL is sent to the server. Thus when the DDL is retrieved the entire CREATE PROCEDURE statement will be one long line with no new line or carriage returns. Example: alter procedure db2inst1.sp1 replace version v1 () DISABLE DEBUG MODE ISOLATION LEVEL CS /* if there is a ' or " in this comment no LF is sent*/ LANGUAGE SQL P1: BEGIN -- Test Insert INSERT INTO T1 VALUES( 11, -- here ' or " has no problem. 55) --Parm2 ; -- end of procedure END P1@ select * from /* it is new 'style comment */ -- normal comment T1@ The problem is with /* ... */ style of comment only. | |
Problem-Zusammenfassung: | |
**************************************************************** * USERS AFFECTED: * * All users using CLP script and quote under new style * * comment. * **************************************************************** * PROBLEM DESCRIPTION: * * When using single or double quote inside new style comment * * (/* ... */) with a sql statement in a clp script file, sql * * fails with SQL0104N error. * * * * users executing ALTER PROCEDURE will * * have the Line Feed (0xA) character removed before the DDL is * * * * sent to the server. Thus when the DDL is retrieved the * * entire * * CREATE PROCEDURE statement will be one long line with no new * * * * line or carriage returns. * * * * * * Example: * * * * alter procedure db2inst1.sp1 replace version v1 () * * * * DISABLE DEBUG MODE * * * * ISOLATION LEVEL CS /* if there is a ' or " in this * * comment * * no LF is sent*/ * * LANGUAGE SQL * * * * P1: BEGIN * * -- Test Insert * * * * INSERT INTO T1 VALUES( * * * * 11, -- here ' or " has no problem. * * * * 55) --Parm2 * * ; * * -- end of procedure * * END P1@ * * * * * * select * from /* it is new 'style comment */ * * * * -- normal comment * * T1@ * * * * * * The problem is with /* ... */ style of comment only. * **************************************************************** * RECOMMENDATION: * * Upgrade to DB2 v9.5 Fixpack 9. * **************************************************************** | |
Local-Fix: | |
Do not use single quotes (') or double quotes (") inside a new style comment. Another alternative is to use the old style comments instead (e.g. -- Line 1) | |
verfügbare FixPacks: | |
DB2 Version 9.5 Fix Pack 9 for Linux, UNIX, and Windows | |
Lösung | |
Problem was first fixed in v9.5 Fixpack 9. At minimum this fix should be applied to the system executing the SQL statements. | |
Workaround | |
Do not use single quotes (') or double quotes (") inside a new style comment. Another alternative is to use the old style comments instead (e.g. -- Line 1) | |
Bug-Verfolgung | |
Vorgänger : APAR is sysrouted TO one or more of the following: IC76259 Nachfolger : | |
Weitere Daten | |
Datum - Problem gemeldet : Datum - Problem geschlossen : Datum - der letzten Änderung: | 06.05.2011 12.03.2012 12.03.2012 |
Problem behoben ab folgender Versionen (IBM BugInfos) | |
9.5.FP9 | |
Problem behoben lt. FixList in der Version | |
9.5.0.9 |