Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Question: Finding the nth row in a table
What do you mean by "the n'th row" in the table ?
The N'th PHYSICAL row ? You seem to imply an order of some sort ?
-- /// Karl (O O) ------------oOO--(_)--OOo------------ Heber Ferraz-Leite <hferraz_at_via.at> wrote in article <347a8aba.6540154_at_news.via.at>...Received on Wed Nov 26 1997 - 00:00:00 CST
> On Mon, 24 Nov 97 18:18:49 GMT, ndnguyen_at_ix.netcom.com (Nguyen Nguyen)
> wrote:
>
> >Does anyone know that best way to find the nth row in a table?
> >I tried to use rowid, but it doesn't seem to work. Is using the
> >function chartorowid() the right approach?
>
> select whatever from atable where rownum=n oder by whatever;
>
> You need the order by in this case, since you need to tell the
> database you want the nth according to this ordering. Otherwise you
> will receive a random order. (Not really random, but you can't
> control it)
>
>
> Heber
> ---
> hferraz_at_via.at
>