Frequent error in Oracle ORA-04068: existing state of packages has been discarded

前端 未结 5 1638
再見小時候
再見小時候 2021-01-02 03:28

We\'re getting this error once a day on a script that runs every two hours, but at different times of the day.

ERROR at line 1:
ORA-04068: existing state of          


        
5条回答
  •  暗喜
    暗喜 (楼主)
    2021-01-02 04:08

    It seems that you are making changes to your objects that make other objects invalid. Droping an index for example can put into an invalid state all the packages that dependes on that table. It can have a cascade efect. If the package is invalid, the funciton that depends on the package and the view that uses the function can become invalid. Try to recompile all the objects after every DDL query.

提交回复
热议问题