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: How to get the first 15 records of an Oracle query ?

Re: How to get the first 15 records of an Oracle query ?

From: Mark Styles <lambicm_at_yahoo.com>
Date: Wed, 23 Sep 1998 14:29:17 GMT
Message-ID: <36090558.22913347@news.intra.bt.com>


Wed, 23 Sep 1998 15:23:47 +0100, "John Lillywhite" <jlillywhite_at_iap.org.uk> rambled:
>Albert -
> there is another way:-
>
> SELECT * FROM table WHERE ROWNUM < 16;

I know this must be in a FAQ somewhere, but...

Be careful with the above, the query is not ordered in any reliable way, and applying an ORDER BY clause will break the ROWNUM check.

Mark Styles
Spam my account, lose your account. Clear enough? Religious tolerance is an oxymoron. Received on Wed Sep 23 1998 - 09:29:17 CDT

Original text of this message

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