DB2 - Problem description
Problem IC95350 | Status: Closed |
DB21034E ERROR OCCURS WHEN BLOCK COMMENTS IS AT THE BEGINNING OF FILE AND 'WITH' SQL STATEMENT IS AFTER BLOCK COMMENT. | |
product: | |
DB2 FOR LUW / DB2FORLUW / A50 - DB2 | |
Problem description: | |
When a block comment is inserted at the beginning of a 'with' SQL statement-through DB2 CLP, the SELECT SQL statement may fail even if it should be treated as a comment properly. This problem happens for CLP script and CLP command prompt. Following sql statement returns error DB21034E. $ cat with.sql /* comment */ with tmp (c1) as ( select 1 as c1 from sysibm.sysdummy1 union all select c1 + 1 from sysibm.sysdummy1, tmp where c1<2 ) select c1,'a',char(int(c1*rand())),'a' from tmp ; $ db2 -tvf with.sql /* comment */ with tmp (c1) as ( select 1 as c1 from sysibm.sysdummy1 union all select c1 + 1 from sysibm.sysdummy1, tmp where c1<2 ) select c1,'a',char(int(c1*rand())),'a' from tmp DB21034E The command was processed as an SQL statement because it was not a valid Command Line Processor command. During SQL processing it returned: SQL0084N An EXECUTE IMMEDIATE statement contains a SELECT or VALUES statement. SQLSTATE=42612 | |
Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * ALL * **************************************************************** * PROBLEM DESCRIPTION: * * See Error Description * **************************************************************** * RECOMMENDATION: * * Update to 10.5.0.3 * **************************************************************** | |
Local Fix: | |
Change the position of block comment not to start at the begining of the file. | |
available fix packs: | |
DB2 Version 10.5 Fix Pack 3 for Linux, UNIX, and Windows | |
Solution | |
Problem Fixed In 10.5.0.3 | |
Workaround | |
not known / see Local fix | |
Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 27.08.2013 03.03.2014 03.03.2014 |
Problem solved at the following versions (IBM BugInfos) | |
Problem solved according to the fixlist(s) of the following version(s) | |
10.5.0.3 | |
10.5.0.3 |