Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Recompiling packages on application server
Robert,
Oracle *should* automatically recompile a package when a user goes to use it. In theory you shouldn't need to worry about packages going invalid.
One way to check that you've compiled all your dependencies is to use the DBMS_UTIL.compile_schema procedure. This recompiles all packages in a schema in the proper order.
What errors are your users getting? What platform do you run?
We have a situation where our packages periodically become invalid--even though we don't make any change any dependent objects. Users then get ORA-04020 deadlocks the first time they try to use the package; the compilation process tries to exclusively lock the table and can't. The second time it works fine. I yet haven't found an answer to this problem.
bill milbratz
neodesic
chicago
In article <881rl4$pp9$1_at_nnrp1.deja.com>,
robertdfeinman_at_netscape.net wrote:
> I have packages which are called by the oracle pl/sql
> web server package.
> When they become invalid because of a change in a dependent
> object they need to be recompiled. If they are accessed
> when in an invalid state they web server returns an error
> to the user.
> I was under the impression that the database engine would
> automatically recompile invalid object when they are next
> accessed.
> To correct the problem it is necessary to do an
> alter package xx recompile body and then restart the
> webserver!
> Has anyone had a similar experience?
>
> --
> Robert Feinman, Database Doctor
> robertdfeinman_at_netscape.net
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Mon Mar 06 2000 - 00:00:00 CST
![]() |
![]() |