Re: Which is faster SQL or PL/PGSQL

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: Joe Conway <mail(at)joeconway(dot)com>, Richard Huxton <dev(at)archonet(dot)com>
Cc: Michael Pohl <pgsql(at)newtopia(dot)com>, pgsql-sql(at)postgresql(dot)org, "George A(dot)J" <jinujosein(at)yahoo(dot)com>
Subject: Re: Which is faster SQL or PL/PGSQL
Date: 2003-10-20 18:24:02
Message-ID: 200310201124.02090.josh@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Joe,

> Yes, I believe so (well, actually the optimizer). An inlined SQL
> function ends up behaving like a macro that expands at run time and is
> therefore quite fast -- no function call overhead at all.

... but only in 7.4. In 7.2 and I think in 7.3 this was not implemented.

While we're on the topic, anyone know any good ways to speed up EXECUTE
statements in PL/pgSQL functions?

--
-Josh Berkus
Aglio Database Solutions
San Francisco

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Adam Witney 2003-10-20 18:40:42 Crosstab question
Previous Message Joe Conway 2003-10-20 18:11:36 Re: Which is faster SQL or PL/PGSQL