DB2 - Problem description
Problem IT09332 | Status: Closed |
WRONG RESULTS MAY HAPPEN WHEN ACCESS PLAN CONTAINS INDEX SCAN ON THE OUTER LEG OF THE HASH JOIN | |
product: | |
DB2 FOR LUW / DB2FORLUW / A50 - DB2 | |
Problem description: | |
It is possible to get wrong results when access plan contains index scan on the outer leg of the hash join and filtering is applied to the scan results. Example below will demonstrate the issue. SQL using "WITH RR" will return correct results. SQL without "WITH RR" will return incorrect results. select count(*) from (select rowid rid from test1 where tabschema = 'MYSCHEMA') a , (select rowid rid from test1 where tabname = 'TEST1') b where a.rid = b.rid 1 ----------- 38 1 record(s) selected. select count(*) from (select rowid rid from test1 where tabschema = 'MYSCHEMA') a , (select rowid rid from test1 where tabname = 'TEST1') b where a.rid = b.rid WITH RR 1 ----------- 20020 1 record(s) selected. Access plans will look the same and will have index scan on the outer leg of the hash join. In the problem case we will not qualify all rows on the outer of hash join due to problems with how we apply filtering. | |
Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * Wrong results * **************************************************************** * PROBLEM DESCRIPTION: * * See Error Description * **************************************************************** * RECOMMENDATION: * * Upgrade to v10.5fp6 or latest fixpak or use workaround below * * db2set DB2_TCG_DEFAULT_OPTIONS="set disable_pushdown on". * * restart the instance. * **************************************************************** | |
Local Fix: | |
db2set DB2_TCG_DEFAULT_OPTIONS="set disable_pushdown on". restart the instance. | |
Solution | |
Workaround | |
not known / see Local fix | |
Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 10.06.2015 19.01.2016 09.05.2017 |
Problem solved at the following versions (IBM BugInfos) | |
Problem solved according to the fixlist(s) of the following version(s) | |
10.5.0.7 |