ERROR:-
*********
Error occurred while running ./datapatch -verbose after applying latest patch on 19.0.0.0
Error at line 8325: script md/admin/sdoutlb.plb
– 167/11 PLS-00201: identifier ‘SYS.DBMS_PRIV_CAPTURE’ must be declared
-> Error at line 8326: script md/admin/sdoutlb.plb
– 2307/10 PL/SQL: Statement ignored
-> Error at line 8327: script md/admin/sdoutlb.plb
– 2307/33 PLS-00201: identifier ‘SYS.DBMS_SYSTEM’ must be declared
-> Error at line 8328: script md/admin/sdoutlb.plb
– 3300/13 PL/SQL: Statement ignored
ORA-04063: package body “MDSYS.SDO_CS” has errors
– ORA-06508: PL/SQL: could not find program unit being called: “MDSYS.SDO_CS”
– ORA-06512: at “MDSYS.SDO_CRS_INSERT_TRIGGER”, line 5
– ORA-04088: error during execution of trigger ‘MDSYS.SDO_CRS_INSERT_TRIGGER’
– ORA-06512: at line 14
Cause:-
*********
This package MDSYS.SDO_CS and trigger MDSYS.SDO_CRS_INSERT_TRIGGER is invalid.
SPATIAL component is invalid in the database.
Solution:-
************
Step 1:- To reinstall the whole component.
find $ORACLE_HOME -name “mdinst.sql”
cd $ORACLE_HOME/md/admin
sqlplus / as sysdba
@mdinst.sql
@utlrp.sql
(or)
Step2:- To fix the above error and validate the component.
grant execute on SYS.DBMS_SYSTEM to MDSYS;
grant execute on SYS.DBMS_PRIV_CAPTURE to MDSYS;
alter package MDSYS.SDO_CS compile;
alter package MDSYS.SDO_CS compile body;
alter trigger MDSYS.SDO_CRS_INSERT_TRIGGER compile;