Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: newbie question about rownum

Re: newbie question about rownum

From: Alan Long <tics28_at_>
Date: Thu, 27 Aug 1998 08:14:12 +0100
Message-ID: <tics28-2708980814120001@tics28.sps.mot.com>


In article <6s1gab$imj$1_at_pascal.a2000.nl>, "Arjan van Bentem" <avbentem_at_DONT-YOU-DAREdds.nl> wrote:

> >Create a view of your sql statement, you cant use Order By in a view, but
> you
> >can GROUP BY <name> and it will do an order by.
>
> >Then you select * from view_name where rownum<10;
>
>
> You may do the same, without actually defining a view, using a subquery:
>
> select temp.*
> from
> ( select *
> from my_table
> where ...
> order by ...
> ) temp
> where rownum < 10;
>
> Arjan.

Err...can you have an "order by" in a subquery? I think not

--
Alan Long

email tics28@"spam-off"email.sps.mot.com (remove the "spam-off") Received on Thu Aug 27 1998 - 02:14:12 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US