Title: RE: [PERFORM] SQL Function Performance
> in my case; both direct query and sql function gererate same execution plan. Also, execution plan belongs to the sql function better than direct sql > query plan. But, direct sql result comes less than 1 second. sql function result comes
Title: RE: [PERFORM] SQL Function Performance
I've run into this issue. It basically comes down to the plan that is being used inside the function is not the same as the plan used when you issue the query manually outside of the function. Although I'm no expert on when plans ar
---Original Message---
From: Michael Fuhr
Date: 02/14/06 23:05:55
To: Adnan DURSUN
Cc: pgsql-performance@postgresql.org
Subject: Re: [PERFORM] SQL
Function Performance
>On Tue, Feb 14, 2006 at 11:33:57AM +0200, Adnan DURSUN wrote:
>>
-> Nested Loop
On Tue, Feb 14, 2006 at 11:33:57AM +0200, Adnan DURSUN wrote:
> -> Nested Loop (cost=5.90..267.19 rows=3 width=101) (actual
> time=76.240..30974.777 rows=63193 loops=1)
> -> Nested Loop (cost=5.90..123.48 rows=26 width=73) (actual
> time=32.082..4357.786 rows=14296 loops
From: Michael Fuhr
Date: 02/14/06 03:32:28
To: Tom Lane
Cc: Adnan DURSUN; pgsql-performance@postgresql.org
Subject: Re: [PERFORM] SQL
Function Performance
On Mon, Feb 13, 2006 at 07:57:07PM -0500, Tom Lane wrote:
>> "Adnan DURSUN" <[EMAIL PROTECTED]> writes:
&
On Mon, Feb 13, 2006 at 07:57:07PM -0500, Tom Lane wrote:
> "Adnan DURSUN" <[EMAIL PROTECTED]> writes:
> EXPLAIN ANALYZE EXECUTE stmt (...);
>
> >Here is the EXPLAIN ANALYZE output for prepared statement :
>
> This is exactly the same as the other plan --- you did not parameterize
> the
"Adnan DURSUN" <[EMAIL PROTECTED]> writes:
EXPLAIN ANALYZE EXECUTE stmt (...);
>Here is the EXPLAIN ANALYZE output for prepared statement :
This is exactly the same as the other plan --- you did not parameterize
the query. To see what's going on, you need to insert PREPARE
parameters in
---Original Message---
From: Mark Liberman
Date: 02/14/06 01:46:16
To: Adnan DURSUN; pgsql-performance@postgresql.org
Subject: RE: [PERFORM] SQL
Function Performance
>> in my case; both direct query and sql function gererate
same execution plan. Also, execution plan belo
>From: Mark
Liberman
>Date: 02/13/06
22:09:48
>To: Adnan DURSUN; pgsql-performance@postgresql.org
>Subject: RE: [PERFORM]
SQL Function Performance
>I've run into this issue. It basically comes down to the
plan that is being used inside the function is not the same as
From: Michael Fuhr
Date: 02/13/06
07:46:05
To: Adnan DURSUN
Cc: pgsql-performance@postgresql.org
Subject: Re: [PERFORM] SQL
Function Performance
On Sun, Feb 12, 2006 at 10:25:28PM +0200, Adnan DURSUN wrote:
>> My database has an SQL function. The result co
From: Michael Fuhr
Date: 02/13/06
07:46:05
To: Adnan DURSUN
Cc: pgsql-performance@postgresql.org
Subject: Re: [PERFORM]
SQL Function Performance
On Sun, Feb 12, 2006 at 10:25:28PM +0200, Adnan DURSUN wrote:
>> My database has
On Sun, Feb 12, 2006 at 10:25:28PM +0200, Adnan DURSUN wrote:
> My database has an SQL function. The result comes in 30-40 seconds
> when i use the SQL function. On the other hand; The result comes
> 300-400 milliseconds when i run the SQL statement. Any idea ??
Have you analyzed the tables? If t
If you have only recently analyzed the tables in the query, close your psql
session (if that's what you were using) and then restart it. I've gotten burned
by asking a query using the function, which I believe is when PG creates the
plan for the function, and then making significant changes to t
Hi
all,
My
database has an SQL function. The result comes in 30-40 seconds
when i use the SQL function. On the other hand; The result comes
300-400 mill
On Thu, Sep 29, 2005 at 10:54:58PM +0300, [EMAIL PROTECTED] wrote:
> Hi All,
>
> I have a SQL function like :
>
> CREATE OR REPLACE FUNCTION
> fn_get_yetkili_inisyer_listesi(int4, int4)
> RETURNS SETOF kod_adi_liste_type AS
> $BODY$
> SELECT Y.KOD,Y.ADI
>FROM T_YER Y
> WHERE EX
Hi All,
I have a SQL function like :
CREATE OR REPLACE FUNCTION
fn_get_yetkili_inisyer_listesi(int4, int4)
RETURNS SETOF kod_adi_liste_type AS
$BODY$
SELECT Y.KOD,Y.ADI
FROM T_YER Y
WHERE EXISTS (SELECT 1
FROM T_GUZER G
WHERE (G.BIN_YER_KOD = $1 OR COALESCE($1,0)=0
16 matches
Mail list logo