Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-04068: existing state of packages has been discarded

epipkoJan 12 2022

Oracle 19.3 on Win 2019
Really strange, but after I restored prod backup into test, I am now having one of the packages failing with:
ORA-04068: existing state of packages has been discarded ORA-04061: existing state of package body "xxx_PKG" has been invalidated ORA-04065: not executed, altered or dropped package body "xxx_PKG" ORA-06508: PL/SQL: could not find program unit being called: "xx_PKG" ORA-06512: at line 1
I have a process that loops over files and loads them into database. The process would load all, but the last file. That last file will always fail with above error. Then next set of files will be downloaded and process would again load all but the last one.
It does not happen in prod (from which I restored a backup).
Where would you I start?

Comments
Post Details
Added on Jan 12 2022
7 comments
963 views