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: PUBLIC:Re: Top 10

Re: PUBLIC:Re: Top 10

From: Jomarlen <jomarlen_at_aol.com>
Date: 1997/12/29
Message-ID: <19971229191601.OAA21679@ladder01.news.aol.com>#1/1

>Try:
>
>Select *
>from xyz
>where rownum <= 10
>
>and you get the first 10 rows of the select result
>
>

This comes up at least once a month!
Sure, it works if you don't include
an ORDER BY.

If you do then you get the first 10 records that would have been retrieved BEFORE
the ORDER BY is applied. which is probably not what you want.

John



John C. Lennon
Utility Partners Inc.
4300 West Tropicana Blvd LVO-UPL
Las Vegas NV 89103

FOR UTILITY PARTNERS EMPLOYMENT
OPPORTUNITIES VISIT www.utilpart.com

e-mail: jomarlen_at_aol.com
Web Site: http://members.aol.com/jomarlen/

The views expressed in this message
are those of the author and not
necessarily those of U.P. Inc.
and/or its employees.


Received on Mon Dec 29 1997 - 00:00:00 CST

Original text of this message

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