DB2 - Problem description
Problem IC92049 | Status: Closed |
DB2 MIGHT PRODUCE SQL0901N WHEN USING RATIO_TO_REPORT OLAP FUNCTION | |
product: | |
DB2 FOR LUW / DB2FORLUW / 970 - DB2 | |
Problem description: | |
Under very rare scenarios, DB2 might give a SQL0901N error message. A. The query has a RATIO_TO_REPORT olap function B. The datatype of the input expression is not decfloat Example: select t1.c1, ratio_to_report(sum(cast(t1.volume as float)))OVER (Partition By t1.c1) from t1 where t1.c2 = 1 group by t1.c1; SQL0901N The SQL statement failed because of a non-severe system error. Subsequent SQL statements can be processed. (Reason "".) SQLSTATE=58004 Similar stack will be dumped in the Trap file: ossDumpStackTraceEx OSSTrapFile::dumpEx sqlo_trce sqloDumpDiagInfoHandler __pthread_mutex_cond_lock pthread_kill sqloDumpEDU sqldDumpContext sqlrr_dump_ffdc sqlzeDumpFFDC sqlzeMapZrc sqlrrMapZrc sqlrimth_divintdfp sqlriSectInvoke sqlrr_open | |
Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * ALL * **************************************************************** * PROBLEM DESCRIPTION: * * See Error Description * **************************************************************** * RECOMMENDATION: * * Upgrade to DB2 Version 9.7 Fix Pack 9 * **************************************************************** | |
Local Fix: | |
Manually rewrite the RATIO_TO_REPORT into a (cast(expression as decfloat))/SUM(expression) over () form | |
available fix packs: | |
DB2 Version 9.7 Fix Pack 9 for Linux, UNIX, and Windows | |
Solution | |
Workaround | |
not known / see Local fix | |
BUG-Tracking | |
forerunner : APAR is sysrouted TO one or more of the following: IC95317 IC96265 follow-up : | |
Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 01.05.2013 19.08.2014 19.08.2014 |
Problem solved at the following versions (IBM BugInfos) | |
9.7.FP9 | |
Problem solved according to the fixlist(s) of the following version(s) | |
9.7.0.9 | |
9.7.0.9 |