Re: query hangs - Mailing list pgsql-performance

From Kevin Grittner
Subject Re: query hangs
Date
Msg-id 4C15FDC1020000250003228B@gw.wicourts.gov
Whole thread Raw
In response to Re: query hangs  (AI Rumman <rummandba@gmail.com>)
List pgsql-performance
AI Rumman <rummandba@gmail.com> wrote:

> [It takes a long time to return 2.6 million rows.]

> Any more idea, please.

I don't recall you telling us exactly what the environment and
connection type is in which you're trying to return this large
result set.  Any specific suggestions would depend on that
information.

I do wonder why you are returning 2.6 million rows.  A result set
that large is rarely useful directly (except during data conversion
or loading of some sort).  Is there any filtering or aggregation
happening on the client side with the received rows?  If so, my
first suggestion would be to make that part of the query, rather
than part of the client code.

> Is table partition a good solution for query optimization?

Table partitioning is useful in some cases, but you haven't told us
anything yet to indicate that it would help here.

-Kevin

pgsql-performance by date:

Previous
From: Andy Colson
Date:
Subject: Re: Dead lock
Next
From: Elias Ghanem
Date:
Subject: Fwd: Dead lock