Re: using a sequence as the functional equivalent to Oracle rownum

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: stafford(at)marine(dot)rutgers(dot)edu
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: using a sequence as the functional equivalent to Oracle rownum
Date: 2006-11-28 20:46:01
Message-ID: 6154.1164746761@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Wm.A.Stafford" <stafford(at)marine(dot)rutgers(dot)edu> writes:
> ... is there a standard PostgreSQL way to select a
> 'block' of rows from a result set based on row number?

LIMIT/OFFSET might be what you are looking for --- it's certainly far
less klugy than a temporary sequence.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Merlin Moncure 2006-11-28 21:00:56 Re: Only MONO/WinForms is a way to go
Previous Message Tom Lane 2006-11-28 20:44:10 Re: backend crash following load command