Cursor fetch performance issue

From: Tony Capobianco <tcapobianco(at)prospectiv(dot)com>
To: pgsql-performance(at)postgresql(dot)org
Subject: Cursor fetch performance issue
Date: 2012-01-24 20:41:40
Message-ID: 1327437700.1968.10.camel@tony1.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

We are migrating our Oracle warehouse to Postgres 9.

This function responds well:

pg=# select public.getMemberAdminPrevious_sp2(247815829, 1,'test(dot)email(at)hotmail(dot)com', 'email', 'test');
getmemberadminprevious_sp2
----------------------------
<unnamed portal 1>
(1 row)

Time: 7.549 ms

However, when testing, this fetch takes upwards of 38 minutes:

BEGIN;
select public.getMemberAdminPrevious_sp2(247815829, 1,'test(dot)email(at)hotmail(dot)com', 'email', 'test');
FETCH ALL IN "<unnamed portal 2>";

How can I diagnose any performance issues with the fetch in the cursor?

Thanks.
Tony

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Pavel Stehule 2012-01-24 20:47:35 Re: Cursor fetch performance issue
Previous Message Dave Crooke 2012-01-24 20:16:19 Can lots of small writes badly hamper reads from other tables?