DB2 - Problem description
Problem IT07303 | Status: Closed |
QUERY CONTAINING A PREDICATE REFERENCING AN XMLTABLE COLUMN IN CORRELATED QUERY BLOCK MAY FAIL WITH SQL0901 ERROR | |
product: | |
DB2 FOR LUW / DB2FORLUW / A50 - DB2 | |
Problem description: | |
A query which satisfies the following conditions may fail with an SQL0901N error: (a) the query references an XMLTABLE (b) the query references a column from the XMLTABLE in a correlated query block (c) the query also references the same column outside the correlated query block. For example: SELECT FROM XMLTABLE(.... COLUMNS "C2" INTEGER PATH ..., ) AS XT, T1 WHERE T1.C1 = (SELECT MAX(T2.C1) FROM T2 WHERE T2.C1 <= XT.C2) AND XT.C2 >= 5 The db2diag.log will show a message similar to the following: FUNCTION: DB2 UDB, relation data serv, sqlrr_dump_ffdc, probe:300 DATA #1 : SQLCA, PD_DB2_TYPE_SQLCA, 136 bytes sqlcaid : SQLCA sqlcabc: 136 sqlcode: -901 sqlerrml: 29 sqlerrmc: contextPid must be of XMLTYPE sqlerrp : SQLNQ82A sqlerrd : (1) 0x00000000 (2) 0x00000000 (3) 0x00000000 (4) 0x00000000 (5) 0xFFFFFF9C (6) 0x00000000 sqlwarn : (1) (2) (3) (4) (5) (6) (7) (8) (9) (10) (11) | |
Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * ALL * **************************************************************** * PROBLEM DESCRIPTION: * * See Error Description * **************************************************************** * RECOMMENDATION: * * Upgrade to DB2 Version 10.5 Fix Pack 7. * **************************************************************** | |
Local Fix: | |
Solution | |
First fixed in Version 10.5 Fix Pack 7. | |
Workaround | |
not known / see Local fix | |
Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 23.02.2015 09.02.2016 09.02.2016 |
Problem solved at the following versions (IBM BugInfos) | |
Problem solved according to the fixlist(s) of the following version(s) | |
10.5.0.7 |