Re: Table sampling question

From: Kirk Bradley - Mainframe and Integration Technologies <kbradley_at_130.35.1.6>
Date: 1 Mar 1995 23:20:42 GMT
Message-ID: <3j2vgb$qaa_at_dcsun4.us.oracle.com>


argh.. this is a SQL construct NOT a SQL*Plus construct. look in the SQL reference manual

MLee417633 (mlee417633_at_aol.com) wrote:
: In response to using only sql to return nth rows from a paricular table:
 

: create view tablea_vw as select *, rownum rn from tablea;
: select * from tablea_vw where mod(rn,100) = 0;
 

: This will return every 100th row from tablea. As far as I know, you
: cannot do this directly from one sql statement. The rownum select item in
: the create view clause is a SQL*Plus pseudo column. Refer to the SQL*Plus
: manual for a description if you are not familiar.
 

: Hope this helps.
: Mike Lee leemic_at_versar.com

--
Kirk Bradley
Oracle Corporation
Mainframe and Integration Technologies Group
Received on Thu Mar 02 1995 - 00:20:42 CET

Original text of this message