DB2 - Problembeschreibung
Problem IC64585 | Status: Geschlossen |
SQL SCALAR FUNCTION IN SELECT-CLAUSE BLOCKS USE OF UPDATE-CLAUSE WITH SQLSTATE 42829 | |
Produkt: | |
DB2 FOR LUW / DB2FORLUW / 970 - DB2 | |
Problembeschreibung: | |
The following query should be valid: select T1.C1, MYSQLUDF( T1.C2 ) A from T1 for update where MYSQLUDF is a SQL scalar function. The expected result is that the update-clause implicitly includes all updatable columns of table T1. However, the query fails to compile with the following error: SQL0511N The FOR UPDATE clause is not allowed because the table specified by the cursor cannot be modified. SQLSTATE=42829 | |
Problem-Zusammenfassung: | |
**************************************************************** * USERS AFFECTED: * * ALL * **************************************************************** * PROBLEM DESCRIPTION: * * The following query should be valid: * * * * * * * * select T1.C1, MYSQLUDF( T1.C2 ) A from T1 for update * * * * * * * * where MYSQLUDF is a SQL scalar function. The expected * * result is * * that the update-clause implicitly includes all updatable * * columns * * of table T1. However, the query fails to compile with the * * * * following error: * * * * * * * * SQL0511N The FOR UPDATE clause is not allowed because the * * table * * specified by the cursor cannot be modified. SQLSTATE=42829 * **************************************************************** * RECOMMENDATION: * * Upgrade to DB2 version 9.1 fix pack 1. * * * * Alternatively, explicitly specify the updatable columns in * * the update-clause. For example, using the query above: * * * * * * * * select T1.C1, MYSQLUDF( T1.C2 ) A from T1 for update of * * C1, C2; * **************************************************************** | |
Local-Fix: | |
Explicitly specify the updatable columns in the update-clause. For example, using the query above: select T1.C1, MYSQLUDF( T1.C2 ) A from T1 for update of C1, C2; | |
verfügbare FixPacks: | |
DB2 Version 9.7 Fix Pack 1 for Linux, UNIX, and Windows | |
Lösung | |
Fixed in DB2 version 9.1 fix pack 1 | |
Workaround | |
keiner bekannt / siehe Local-Fix | |
Weitere Daten | |
Datum - Problem gemeldet : Datum - Problem geschlossen : Datum - der letzten Änderung: | 17.11.2009 17.02.2010 17.02.2010 |
Problem behoben ab folgender Versionen (IBM BugInfos) | |
9.1.FP1 | |
Problem behoben lt. FixList in der Version | |
9.7.0.1 |