Upgrade from 12.2.0.1 to 18c fails with error - ORA-02303: cannot drop or replace a type with type or table dependents
(Doc ID 2554586.1)
Last updated on APRIL 17, 2023
Applies to:
Oracle Database - Enterprise Edition - Version 18.3.0.0.0 and laterInformation in this document applies to any platform.
Symptoms
Upgrading the database from 12.2.0.1 to 18c .Following error is encountered-
11:40:39 SQL> -- contains dbms_output (odci procedures dependent on this)
11:40:39 SQL> @@dbmsotpt
11:40:39 SQL> rem
11:40:39 SQL> rem $Header: rdbms/admin/dbmsotpt.sql /main/29 2014/02/20 12:45:51 surman Exp $
11:40:39 SQL> rem
11:40:39 SQL> Rem Copyright (c) 1991, 2013, Oracle and/or its affiliates.
11:40:39 SQL> Rem All rights reserved.
11:40:39 SQL> Rem NAME
11:40:39 SQL> Rem dbmsotpt.sql - used by sql*dba 'set serveroutput on' cmd
11:40:39 SQL> Rem DESCRIPTION
11:40:39 SQL> Rem NOTES
11:40:39 SQL> Rem SQL*DBA and SQL*PLUS depend on this package.
11:40:39 SQL> Rem RETURNS
11:40:39 SQL> @@dbmsotpt
11:40:39 SQL> rem
11:40:39 SQL> rem $Header: rdbms/admin/dbmsotpt.sql /main/29 2014/02/20 12:45:51 surman Exp $
11:40:39 SQL> rem
11:40:39 SQL> Rem Copyright (c) 1991, 2013, Oracle and/or its affiliates.
11:40:39 SQL> Rem All rights reserved.
11:40:39 SQL> Rem NAME
11:40:39 SQL> Rem dbmsotpt.sql - used by sql*dba 'set serveroutput on' cmd
11:40:39 SQL> Rem DESCRIPTION
11:40:39 SQL> Rem NOTES
11:40:39 SQL> Rem SQL*DBA and SQL*PLUS depend on this package.
11:40:39 SQL> Rem RETURNS
11:40:39 SQL>
11:40:39 SQL> Rem This script must be run as user SYS.
11:40:39 SQL>
11:40:39 SQL> -- create varray type of varchar2(32767)
11:40:39 SQL> CREATE OR REPLACE TYPE dbmsoutput_linesarray IS
11:40:39 2 VARRAY(2147483647) OF VARCHAR2(32767);
11:40:39 3 /
CREATE OR REPLACE TYPE dbmsoutput_linesarray IS
*
ERROR at line 1:
ORA-02303: cannot drop or replace a type with type or table dependents
11:40:39 SQL> Rem This script must be run as user SYS.
11:40:39 SQL>
11:40:39 SQL> -- create varray type of varchar2(32767)
11:40:39 SQL> CREATE OR REPLACE TYPE dbmsoutput_linesarray IS
11:40:39 2 VARRAY(2147483647) OF VARCHAR2(32767);
11:40:39 3 /
CREATE OR REPLACE TYPE dbmsoutput_linesarray IS
*
ERROR at line 1:
ORA-02303: cannot drop or replace a type with type or table dependents
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Cause |
Solution |