"Chris Ochs" <chris@paymentonline.com> writes:
> I am pretty sure I know this already, but every time you run a Pl/Perl
> function it is just like running a perl script as far as having to load and
> compile the code right?
No, the perl script gets compiled only the first time the function is
invoked (within a given backend session). Subsequent calls to the
function use the already-compiled function object. I'm not clear on
exactly how much overhead this saves in Perl, but it's certainly not
as bad as re-loading a script on each call.
I believe all the PL languages have comparable optimizations.
regards, tom lane