Fw: stored procedures for complex SELECTs

From: <ipv(at)tinet(dot)org>
To: <pgsql-sql(at)postgresql(dot)org>
Subject: Fw: stored procedures for complex SELECTs
Date: 2006-01-25 03:01:07
Message-ID: 003901c6215b$97036340$0600000a@matt.mutua
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

For better performance, try to utilize prepared statements;

example:

PREPARE CPrep_Clients (varchar(20)) AS
SELECT * FROM client WHERE nom = $1;

EXECUTE CPrep_Clients('Francio');

In my system, over 51ms difference between standard select (prepared
by-pass
planification/optimization)

Regards

> ----- Original Message -----
> From: <alex-lists-pgsql(at)yuriev(dot)com>
> To: <pgsql-sql(at)postgresql(dot)org>
> Sent: Thursday, January 19, 2006 12:17 AM
> Subject: [SQL] stored procedures for complex SELECTs
>
>
>>
>> Are there performance advantages that can be achieved by wrapping a
>> complex SELECT into a stored procedure?
>>
>> Alex
>>
>> ---------------------------(end of broadcast)---------------------------
>> TIP 4: Have you searched our list archives?
>>
>> http://archives.postgresql.org
>>
>>
>

Browse pgsql-sql by date

  From Date Subject
Next Message ipv 2006-01-25 03:14:12 Re: sorting by day of the week
Previous Message Joseph Shraibman 2006-01-25 02:39:11 Re: sorting by day of the week