DB2 - Problem description
Problem IC65904 | Status: Closed |
DROP SCHEMA RETURNS SQL0901N WITH REASON "UNKNOW OBJECT TYPE" INSTEAD OF SQL0478N | |
product: | |
DB2 FOR LUW / DB2FORLUW / 970 - DB2 | |
Problem description: | |
When dropping a schema (ie. DROP SCHEMA <schemaName> RESTRICT), you are required to have all objects removed from that schema prior to being allowed to drop it. This APAR addresses an issue where the DROP SCHEMA statement returns SQL0901N with reason "Unknow object type" instead of returning the expected sqlcode SQL0478N with the name and type of the object that still remains in the schema. This occurs when there remains one or more tables that are either a) a Created Global Temporary Table (CGTT) or b) a table that is in detached state due to an alter table detach operation. | |
Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * All DB2 Version 9.7 GA through to Fix Pack 1 servers, on * * Linux, Unix or Windows platforms. * **************************************************************** * PROBLEM DESCRIPTION: * * Created Global Temporary tables along with tables in * * detached state were missing functionality for returning the * * correct SQL0478N error. * **************************************************************** * RECOMMENDATION: * * Update your instance to DB2 Version 9.7 Fix Pack 2 or see * * local fix for more details. * **************************************************************** | |
Local Fix: | |
Identify all the table objects remaining in the SYSCAT.TABLES catalog view which belong to this schema, and drop each one of them. You can identify these objects with the following query: select tabschema, tabname, type from syscat.tables where tabschema='<schemaName>' | |
available fix packs: | |
DB2 Version 9.7 Fix Pack 2 for Linux, UNIX, and Windows | |
Solution | |
Problem first fixed in DB2 Version 9.7 Fix Pack 2 and all subsequent Fix Packs. | |
Workaround | |
not known / see Local fix | |
Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 27.01.2010 08.04.2010 08.04.2010 |
Problem solved at the following versions (IBM BugInfos) | |
9.7.FP2 | |
Problem solved according to the fixlist(s) of the following version(s) | |
9.7.0.2 |