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 IC86178 Status: Closed

DB2 CAN HANG WHEN COMPILING A CERTAIN TYPE OF SQL STATEMENTS

product:
DB2 FOR LUW / DB2FORLUW / 970 - DB2
Problem description:
When a SQL statement meets the following conditions, DB2 can 
hang, i.e. DB2 can be stuck in an infinite loop, when compiling 
such SQL statement. 
 
1) The SQL statement is eligible for star join planning, that 
is, DB2 can detect a star schema in the tables that involve in 
the SQL statement. 
 
2) The SQL statement contains more than 10 disconnected tables. 
Disconnected tables refer to tables that are not connected by 
join predicates, or the joins are effective Cartesian. For 
example, the following join is effective Cartesian: 
 
select * 
from t1, t2 
where t1.c1=t2.c1 and t1.c1=1 
 
Under transitivity, the join predicate can be replaced by a 
local predicate: 
 
select * 
from t1, t2 
where t2.c1=1 and t1.c1=1 
 
 
For the DB2 agent that is stuck in the compiling, You can 
observe the following stack tracebacks repeatedly occur. Note 
the common calling function sqlno_default_next_part(): 
 
sqlno_decide_join_order 
sqlno_common_test_criteria 
sqlno_default_next_part 
 
or 
 
sqlno_collect_ajp 
sqlno_common_test_criteria 
sqlno_default_next_part
Problem Summary:
**************************************************************** 
* USERS AFFECTED:                                              * 
* All users of DB2 V9.7                                        * 
**************************************************************** 
* PROBLEM DESCRIPTION:                                         * 
* See Error Description                                        * 
**************************************************************** 
* RECOMMENDATION:                                              * 
* Upgrade to fix pack 8.                                       * 
****************************************************************
Local Fix:
Disable star join or disable dynamic programming join 
enumeration by using optimization level 0,1,2, or 3 to 
compile the query.
available fix packs:
DB2 Version 9.7 Fix Pack 8 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 9 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 9a for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 10 for Linux, UNIX, and Windows

Solution
First fixed in V9.7 fp8
Workaround
Disable star join or disable dynamic programming join 
enumeration by using optimization level 0,1,2, or 3 to 
compile the query.
Timestamps
Date  - problem reported    :
Date  - problem closed      :
Date  - last modified       :
28.08.2012
01.04.2013
21.05.2013
Problem solved at the following versions (IBM BugInfos)
9.7.FP8
Problem solved according to the fixlist(s) of the following version(s)
9.7.0.8 FixList