DB2 - Problembeschreibung
Problem IC86703 | Status: Geschlossen |
SYSPROC.ALTOBJ FAILS WITH -204 ERROR FOR LOWERCASE OBJECT NAMES AND -305 ERROR IN DB2_COMPATIBILITY_VECTOR | |
Produkt: | |
DB2 FOR LUW / DB2FORLUW / 970 - DB2 | |
Problembeschreibung: | |
This APAR deals with two issues with the SYSPROC.ALTOBJ routine: Problem 1: SYSPROC.ALTOBJ returns a -443 error with a SQLCODE of -204 (object not found) when the object passed into SYSPROC.ALTOBJ is in lowercase as opposed to uppercase. For example: C:\>db2 "create table test(id varchar(20),name varchar(40),phone varchar(20))" DB20000I The SQL command completed successfully. C:\>db2 "insert into test values ('xx','bill','1234567890')" DB20000I The SQL command completed successfully. C:\>db2 "insert into test values ('yy','sam','1234567890')" DB20000I The SQL command completed successfully. C:\>db2 "CALL SYSPROC.ALTOBJ('APPLY_CONTINUE_ON_ERROR', 'create table test(id varchar(20), name varchar(50), phone varchar(20))', -1, ?)" SQL0443N Routine "SYSPROC.ALTOBJ" (specific name "ALTOBJ") has returned an error SQLSTATE with diagnostic text "SQL0204 Token: DB2ADMIN .test". SQLSTATE=38553 C:\>db2 "CALL SYSPROC.ALTOBJ('APPLY_CONTINUE_ON_ERROR', 'create table TEST(id varchar(20), name varchar(50), phone varchar(20))', -1, ?)" Value of output parameters -------------------------- Parameter Name : ALTER_ID Parameter Value : 1 Parameter Name : MSG Parameter Value : SELECT OBJ_TYPE, OBJ_SCHEMA, OBJ_NAME, SQL_OPERATION, SQL_STMT, EXEC_MODE, EXEC_SEQ FROM SYSTOOLS.ALTOBJ_INFO_V WHERE ALTER_ID=1 AND EXEC_MODE LIKE '_1______' ORDER BY EXEC_SEQ. Return Status = 0 Using lowercase "test" failed, but uppercase "TEST" worked. SYSPROC.ALTOBJ should be able to process the statement by defaulting the object name in uppercase unless the object name is enclosed in double quotes. Problem 2: SYSPROC.ALTOBJ returns a -443 error with a SQLCODE of -305 (NULL cannot be used) when DB2_COMPATIBILITY_VECTOR=ORA is set. For example: C:\>db2set -all ... [i] DB2_COMPATIBILITY_VECTOR=ORA ... C:\>db2 connect to sample Database Connection Information Database server = DB2/NT 9.7.6 SQL authorization ID = DB2ADMIN Local database alias = SAMPLE C:\>db2 "create table test(id varchar(20),name varchar(40),phone varchar(20))" DB20000I The SQL command completed successfully. C:\>db2 "insert into test values ('xx','bill','1234567890')" DB20000I The SQL command completed successfully. C:\>db2 "insert into test values ('yy','sam','1234567890')" DB20000I The SQL command completed successfully. C:\>db2 "CALL SYSPROC.ALTOBJ('APPLY_CONTINUE_ON_ERROR', 'create table TEST(id varchar(20), name varchar(50), phone varchar(20))', -1, ?)" SQL0443N Routine "SYSPROC.ALTOBJ" (specific name "ALTOBJ") has returned an error SQLSTATE with diagnostic text "SQL0305 ALTER_ID=1". SQLSTATE=38553 | |
Problem-Zusammenfassung: | |
**************************************************************** * USERS AFFECTED: * * users who use altobj procedure * **************************************************************** * PROBLEM DESCRIPTION: * * See Error Description * **************************************************************** * RECOMMENDATION: * * upgrade to v9.7fp8 * **************************************************************** | |
Local-Fix: | |
For problem 1, specify the object name in uppercase. For problem 2 manually alter the table using the "ALTER" DB2 command if DB2_COMPATIBILITY_VECTOR is required. | |
verfügbare FixPacks: | |
DB2 Version 9.7 Fix Pack 8 for Linux, UNIX, and Windows | |
Lösung | |
Workaround | |
keiner bekannt / siehe Local-Fix | |
Bug-Verfolgung | |
Vorgänger : APAR is sysrouted TO one or more of the following: IC87091 Nachfolger : | |
Weitere Daten | |
Datum - Problem gemeldet : Datum - Problem geschlossen : Datum - der letzten Änderung: | 20.09.2012 01.04.2013 01.04.2013 |
Problem behoben ab folgender Versionen (IBM BugInfos) | |
9.7.FP8 | |
Problem behoben lt. FixList in der Version | |
9.7.0.8 |