DB2 - Problembeschreibung
| Problem IC83437 | Status: Geschlossen |
ADMIN_MOVE_TABLE PROCEDURE RETURNS SQL0969N, SQL1188N or SQL0408N ERROR CODE. | |
| Produkt: | |
DB2 FOR LUW / DB2FORLUW / 980 - DB2 | |
| Problembeschreibung: | |
If a table has a column named CURRENT_TIME which is of type
TIME, then ADMIN_MOVE_TABLE procedure passes without any error
but the value of "CURRENT TIME" special register is inserted
into the target table instead of the correct value from the
source table. This problem results in data loss and incorrect
results being stored in the target table.
The ADMIN_MOVE_TABLE procedure returns SQL0408N, SQL0969N or
SQL1188N error message when the source table has a column named
CURRENT_TIME but its type is not defined as TIME.
For example:
$ db2 "create table tab_with_time (current_time int not null)"
DB20000I The SQL command completed successfully.
$ db2 "call admin_move_table ('WEIREN', 'TAB_WITH_TIME',
'IBMDB2SAMPLEREL', 'IBMDB2SAMPLEREL', 'IBMDB2SAMPLEREL', '','',
'', '', '', 'MOVE')"
SQL0408N A value is not compatible with the data type of its
assignment target. Target name is "CURRENT_TIME".
SQLSTATE=42821
ADMIN_MOVE_TABLE procedure may also return SQL0969N or SQL1188N
error messages instead:
SQL0969N There is no message text corresponding to SQL error
"-99999" in the message file on this workstation. The error
was returned from module "SQL09073" with original tokens "".
SQL1188N Column "9" of the SELECT or VALUES statement is not
compatible with table column "9". The source column has sqltype
"388", and the target column has sqltype "384".
In the above example of SQL1188N message, SQL data type
(SQLTYPE) 388 is TIME and SQLTYPE 384 is DATE. This shows that
the original type of CURRENT_TIME column is defined as DATE.
More information on the SQL data types mentioned in SQL error
messages can be found in the DB2 for Linux, UNIX, and Windows
Information Center. | |
| Problem-Zusammenfassung: | |
**************************************************************** * USERS AFFECTED: * * ALL * **************************************************************** * PROBLEM DESCRIPTION: * * See Error Description * **************************************************************** * RECOMMENDATION: * * Upgrade to DB2 Version 9.8 Fix Pack 5 * **************************************************************** | |
| Local-Fix: | |
Switch the table to offline mode and temporarily rename the column CURRENT_TIME to a different name. Then call the ADMIN_MOVE_TABLE procedure, and finally change the column name back to CURRENT_TIME. | |
| Lösung | |
First fixed in Version 9.8 Fix Pack 5 | |
| Workaround | |
keiner bekannt / siehe Local-Fix | |
| Weitere Daten | |
Datum - Problem gemeldet : Datum - Problem geschlossen : Datum - der letzten Änderung: | 14.05.2012 22.08.2012 22.08.2012 |
| Problem behoben ab folgender Versionen (IBM BugInfos) | |
9.8.FP5 | |
| Problem behoben lt. FixList in der Version | |
| 9.8.0.5 |
|