Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: PLSQL execution model

Re: PLSQL execution model

From: Arien Malec <amalec_at_slip.net>
Date: Fri, 27 Aug 1999 17:03:34 -0700
Message-ID: <37C72756.E93BA380@slip.net>


rtproffitt_at_my-deja.com wrote:

> The first time a package is called it must
> be cached in memory, this takes time...
> The first time is always the slowest.
> Once it is cached it stays in memory,
> so all subsquent references to it are fast.

It is possible, in reference to the original poster's question, for the package to be compiled when it was called (if package on which it depends had been previously recompiled, for instance), but the slowness observed is most likely to be attributed to loading the package into the cache.

> I am not sure what you mean by pre-fetching the
> data, but you might be able to write the package
> to use Reference Cursor construct, and then
> open the cursor at program initialization time,
> then not loop through the cursor until user wants to...
> Comments anyone?

There is the package initialization section, where one could write an intializer. E.g.,

PACKAGE BODY pname
IS
variable_to_intialize
--stuff
BEGIN
    variable_to_initialize :=
initialization_function_that_calculates_whatever; END pname; Received on Fri Aug 27 1999 - 19:03:34 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US