Site icon IT Tutorial

ORA-06575: Package or function is in an invalid state

I got ” ORA-06575: Package or function is in an invalid state ”  error in Oracle database.

 

ORA-06575: Package or function is in an invalid state

 

Details of error are as follows.

ORA-06575: Package or function string is in an invalid state.

Cause: A SQL statement references a PL/SQL function that is in an invalid state. 
Oracle attempted to compile the function, but detected errors.

Action: Check the SQL statement and the PL/SQL function for syntax errors or incorrectly 
assigned, or missing, privileges for a referenced object.

 

 

 

Package or function string is in an invalid state

This ORA-06575 error is related with the SQL statement references a PL/SQL function that is in an invalid state.
Oracle attempted to compile the function, but detected errors

Check the SQL statement and the PL/SQL function for syntax errors or incorrectly assigned, or missing, privileges for a referenced object.

 

You can use the SHOW ERROR command to view the errors of package or function as follows:

To solve this error, compile package or function as follows.

alter package PACKAGE_NAME compile;

alter function FUNCTION_NAME compile;

 

OR

You can run utlrp.sql ( under $ORACLE_HOME/rdbms/admin ) to compile all invalid objects.

SQL> @utlrp.sql

 

 

Do you want to learn Oracle Database for Beginners, then read the following articles.

Oracle Tutorial | Oracle Database Tutorials for Beginners ( Junior Oracle DBA )

 

Exit mobile version