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: TurkBear <johng_at_mm.com>
Date: Wed, 23 Sep 1998 14:52:23 GMT
Message-ID: <360a0a9b.4303978@news2.mm.com>


"Albert FEDIDA" <afedida_at_club-internet.fr> wrote:

>I wonder if it is possible in SQL Oracle to get the first 15 records
>for a query?
>With MS-Access, it's as simple as :
>
>SELECT TOP 15 FROM TABLE;
>
>Thanks for your help.
>
>Albert
>
>

Depends on what you mean by the 'first' 15 records...Oracle stores data in an arbitrary order so the rows retrieved absent some qualifier ( where... or Order by ) will be 'random' - to get 'only' ( not necessarily 'first' ) 15 records use where rownum < 16 ;

To reply please remove the 'nospam' part of the address Received on Wed Sep 23 1998 - 09:52:23 CDT

Original text of this message

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