Re: Writing most code in Stored Procedures

From: Guy Rouillier <guyr-ml1(at)burntmail(dot)com>
To: PgSQL General ML <pgsql-general(at)postgresql(dot)org>
Subject: Re: Writing most code in Stored Procedures
Date: 2007-08-19 04:19:45
Message-ID: 46C7C4E1.3000607@burntmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Ron Johnson wrote:

> So why is Perl-SP-INSERT so much slower than Perl-SQL-INSERT?
>
> (I can imagine that the SP code path would be longer, but since IO
> is the slowest part of the system, I'm surprised that it's *that*
> much slower.)

I'm guessing that since PG allows overloaded SP names, the slowness is
coming from resolving which SP to run. But that is just a guess. In my
environment, I don't *have* overloaded SPs, only a single version of a
given name. But when I was doing the conversion from Oracle, it took me
a couple tries to get the SP signatures correct, so I'm pretty sure PG
is still going through the resolution logic, even if you only have a
single instance of a given name.

--
Guy Rouillier

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Felix Ji 2007-08-19 04:34:48 query large amount of data in c++ using libpq
Previous Message Joey K. 2007-08-19 04:13:30 Seeking datacenter PITR backup procedures [RESENDING]