hey people,
today I ran into some very nice (= horrible) problems. I have a package P which inserts into table TA. I also have some triggers TR, which use functions from package P. when I try to alter table TA (add a column), I get the following error (CHANGE_HISTORY is the name of the package):
ORA-00604: error occurred at recursive SQL level 1
ORA-04068: existing state of packages has been discarded
ORA-04061: existing state of package body "D_NTS_01_DEV_1000.CHANGE_HISTORY" has been invalidated
ORA-06508: PL/SQL: could not find program unit being called: "D_NTS_01_DEV_1000.CHANGE_HISTORY"
ORA-06512: at line 12
this causes that the package P becomes invalid (although no column has been added to table TA)
After that, I execute the exact same statement to add a column to table TA, and it works. The package becomes valid again.
So... Here is the question: why is that happening? What can I do to not execute every ddl-statement twice?
thx for your help in advance