MINI MINI MANI MO

Path : /proc/self/root/opt/oracle/product/18c/dbhomeXE/md/admin/
File Upload :
Current File : //proc/self/root/opt/oracle/product/18c/dbhomeXE/md/admin/seme101.sql

Rem
Rem $Header: sdo/admin/seme101.sql /main/5 2017/05/26 16:34:19 rjanders Exp $
Rem
Rem seme101.sql
Rem
Rem Copyright (c) 2007, 2017, Oracle and/or its affiliates. 
Rem All rights reserved.
Rem
Rem    NAME
Rem      seme101.sql - <one-line expansion of the name>
Rem
Rem    DESCRIPTION
Rem      <short description of component this file declares/defines>
Rem
Rem    NOTES
Rem      <other useful comments, qualifications, etc.>
Rem
Rem    BEGIN SQL_FILE_METADATA
Rem    SQL_SOURCE_FILE: sdo/admin/seme101.sql
Rem    SQL_SHIPPED_FILE: md/admin/seme101.sql
Rem    SQL_PHASE: DOWNGRADE 
Rem    SQL_STARTUP_MODE: NORMAL
Rem    SQL_IGNORABLE_ERRORS: NONE 
Rem    SQL_CALLING_FILE: NONE 
Rem    END SQL_FILE_METADATA
Rem    
Rem    MODIFIED   (MM/DD/YY)
Rem    rjanders    05/10/17 - #26037683: Raise 'when other' exceptions
Rem    rjanders    03/23/17 - #25437999: Remove 'when others then NULL'
Rem                           handlers
Rem    rjanders    03/15/13 - #16473696: Start/End _ORACLE_SCRIPT
Rem                           initialization
Rem    sdas        06/17/07 - uninstalls 10.2 RDF (taken from sdoe101.sql)
Rem    sdas        06/17/07 - Created
Rem

Rem ********************************************************************
Rem #16473696: Indicate Oracle-Supplied object
@@?/rdbms/admin/sqlsessstart.sql
Rem ********************************************************************

set echo off

alter session set current_schema=MDSYS;

-- RDF section
declare
  synonym_not_found exception;
  pragma exception_init(synonym_not_found, -01432);
  package_not_found exception;
  pragma exception_init(package_not_found, -04043);
  dependent_objects exception;
  pragma exception_init(dependent_objects, -22933);
begin
   begin
    execute immediate ' drop public synonym sdo_rdf_triple_s ';
    exception
      when synonym_not_found then NULL;
      when dependent_objects then NULL;
      when others then
        SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                               'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')1]: ' || SQLERRM); -- RAISE;
   end;

   begin
    execute immediate 'drop public synonym sdo_rdf_triple ';
    exception
      when synonym_not_found then NULL;
      when others then
        SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                               'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')2]: ' || SQLERRM); -- RAISE;
   end;

   begin
    execute immediate 'drop public synonym sdo_rdf ';
    exception
      when synonym_not_found then NULL;
      when others then
        SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                               'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')3]: ' || SQLERRM); -- RAISE;
   end;

   begin
    execute immediate 'drop package sdo_rdf ';
    exception
      when package_not_found then NULL;
      when others then
        SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                               'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')4]: ' || SQLERRM); -- RAISE;
   end;
   begin
    execute immediate 'drop public synonym sdo_rdf_internal ';
    exception
      when synonym_not_found then NULL;
      when others then
        SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                               'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')5]: ' || SQLERRM); -- RAISE;
   end;

   begin
    execute immediate 'drop package sdo_rdf_internal ';
    exception
      when package_not_found then NULL;
      when others then
            SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                           'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')6]: ' || SQLERRM); -- RAISE;
   end;

   begin
    execute immediate ' drop type body sdo_rdf_triple_s ';
    exception
      when package_not_found then NULL;
      when dependent_objects then NULL;
      when others then
        SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                               'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')7]: ' || SQLERRM); -- RAISE;
   end;
end;
/

declare
  table_not_found exception;
  pragma exception_init(table_not_found, -00942);
  synonym_not_found exception;
  pragma exception_init(synonym_not_found, -01432);
  package_not_found exception;
  pragma exception_init(package_not_found, -04043);
  trigger_not_found exception;
  pragma exception_init(trigger_not_found, -04080);
  dependent_objects exception;
  pragma exception_init(dependent_objects, -22933);
begin
   begin
      execute immediate ' drop table RDF_RULEBASE_MEMBER$ ';
      exception
        when table_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')8]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop table RDF_RULE$ ';
      exception
        when table_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')9]: ' || SQLERRM); -- RAISE;
   end;
    
   begin
      execute immediate ' drop table RDF_RULEBASE$ ';
      exception
        when table_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')10]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop table RDF_PRECOMP_DEP$ ';
      exception
        when table_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')11]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop table RDF_PRECOMP$ ';
      exception
        when table_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')12]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop table RDF_PRECOMP$ ';
      exception
        when table_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')13]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop package RDF_APIS ';
      exception
        when package_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')14]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop package RDF_APIS_INTERNAL ';
      exception
        when package_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')15]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop package RDF_APIS_USER ';
      exception
        when package_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')16]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop procedure load_predefined_rulebases ';
      exception
        when package_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')17]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop type RDF_MATCH_impl_t ';
      exception
        when package_not_found then NULL;
        when dependent_objects then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')18]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop function RDF_MATCH ';
      exception
        when package_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')19]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop public synonym SDO_RDF_MATCH ';
      exception
        when synonym_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')20]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop public synonym RDF_APIS_INTERNAL ';
      exception
        when synonym_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')21]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop public synonym SDO_RDF_INFERENCE ';
      exception
        when synonym_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')22]: ' || SQLERRM); -- RAISE;
   end;

   begin
      execute immediate ' drop trigger sdo_drop_user_before ';
      exception
        when trigger_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')23]: ' || SQLERRM); -- RAISE;
   end;

   -- added
   begin
      execute immediate ' drop package VALUE$CACHE ';
      exception
        when package_not_found then NULL;
        when others then
          SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
                                 'EXCEPTION[seme101.sql(' || $$PLSQL_LINE || ')24]: ' || SQLERRM); -- RAISE;
   end;
     
end;
/

alter session set current_schema=SYS;
call dbms_java.dropjava('-force -synonym -schema MDSYS  md/lib/sdordf.jar');

Rem ********************************************************************
Rem #16473696: Indicate Oracle-Supplied object
@?/rdbms/admin/sqlsessend.sql
Rem ********************************************************************


OHA YOOOO