Hi,
I'm getting a problem with my packages...
I've a lot of packages that work together to perform a task.
There is a "main", central package, that coordenates the functions of anothers auxiliary packages. In a certain moment, a lot of INSERTs will be occur in a table. In this moment, there is a function that disables various FKs, constraints and triggers related to the table that will receive the INSERTs, trying acquire better performance.
The problem is that, after the call of this function (and the constraints being disabled), the main package (and others auxiliary packages) turns INVALID... in some time of the processing, errors like these occur:
"ERROR at line 1:
ORA-04045: errors during recompilation/revalidation of
schema.package_01
ORA-04027: self-deadlock during automatic validation for object
schema.package_02
ORA-06508: PL/SQL: could not find program unit being called:
"schema.package_01"
ORA-06512: at "schema.package_03", line 531
ORA-06512: at line 1"
The above error message is clear, something occurs after disabling/enabling the constraints, and the automatic recompilation of Oracle detects the error and fails in the task of recompilation.
I've tried to use the DBMS_UTILITY.COMPILE_SCHEMA( ) Oracle procedure after disabling the constraints, but without success. The above error continues. I've also tried use the DBMS_UTILITY.VALIDATE( ) Oracle procedure in all the packages involved in my process, but again without success. Always, after disabling/enabling the constraints, in some point of the process, this kind of error occurs, and the process is aborted at that session.
Is there anyone that can help me? Thanks...