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

DB2 MIGHT PRODUCE INCORRECT RESULT WHEN REFERENCING EMPTY TABLE WITH
AGGREGATE FUNCTIONS IN SUBSELECT

product:
DB2 FOR LUW / DB2FORLUW / A10 - DB2
Problem description:
Under rare scenarios, DB2 might produce incorrect results if the 
following conditions are true: 
1) The query references the SYSIBM.SYSDUMMY1 table or a VALUES 
clause. 
2) The sub-select referencing table from 1) contains an 
aggregation function. 
3) The sub-select also has some predicate, which will lead to an 
empty result set. 
4) The topmost select does not reference any column from the 
aforementioned sub-select. 
 
Example: 
select 1 from (SELECT AVG(1) FROM SYSIBM.SYSDUMMY1 where 1=0); 
1 
----------- 
 
  0 record(s) selected. 
 
The correct result is a single row with null value.
Problem Summary:
**************************************************************** 
* USERS AFFECTED:                                              * 
* UNKNOWN                                                      * 
**************************************************************** 
* PROBLEM DESCRIPTION:                                         * 
* See Error Description                                        * 
**************************************************************** 
* RECOMMENDATION:                                              * 
* Upgrade to DB2 version 101 fix pack 5                        * 
****************************************************************
Local Fix:
Solution
The problem was first fixed in DB2 version 101 fix pack 5
Workaround
not known / see Local fix
Timestamps
Date  - problem reported    :
Date  - problem closed      :
Date  - last modified       :
03.11.2014
12.08.2015
12.08.2015
Problem solved at the following versions (IBM BugInfos)
Problem solved according to the fixlist(s) of the following version(s)
10.1.0.5 FixList