Limiting number of rows returned at a time in select query

From: Jon Clements <joncle(at)googlemail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Limiting number of rows returned at a time in select query
Date: 2007-05-24 12:32:25
Message-ID: 1180009945.525480.244750@g4g2000hsf.googlegroups.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi All.

Is there a way inside a query (or connection) to limit the amount of
records returned each chunk by the server? At the moment, I have 22
million records trying to be returned in one-go as the result set. I
have a .NET driver that has a FetchSize option which allows the above
(say returning 10k rows at a time without holding them all in memory);
I'm not sure though if that's a property of the driver / server, as
none of the other interfaces I have seem to include it. It just makes
sense it might be server-side; although, if it's not I'm quite happy
to be corrected.

Any pointers are appreciated.

Cheers,

Jon.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Rich Shepard 2007-05-24 13:05:17 Re: Timestamp with time zone: why not?
Previous Message Wiebe Cazemier 2007-05-24 12:31:17 Re: why postgresql over other RDBMS