Re: Sampling

From: Bricklen Anderson <bricklen_at_shaw.ca>
Date: Tue, 14 May 2002 18:40:44 GMT
Message-ID: <3CE15944.83E66BEE_at_shaw.ca>


[Quoted] try it this way:

[Quoted] select * from au_week_number sample (.05);

hth

Bricklen

Randy Gebhards wrote:
>
> According to O'Reilly book 'Oracle SQL The Essential Reference, pages
> 122, 123' I can add a control structure to the from clause which will
> allow me to retrieve a random sample. However I get command not
> properly ended error messages when following O'Reilly's book.
> Here are the variations I havae tried.
> 1 select *
> 2* from au_week_number SAMPLE .05
> SQL> /
> from au_week_number SAMPLE .05
> *
> ERROR at line 2:
> ORA-00933: SQL command not properly ended
>
> SQL> ED
> Wrote file afiedt.buf
>
> 1 select *
> 2* from au_week_number SAMPLE 0.05
> SQL> /
> from au_week_number SAMPLE 0.05
> *
> ERROR at line 2:
> ORA-00933: SQL command not properly ended
>
> SQL> ED
> Wrote file afiedt.buf
>
> 1 select *
> 2* from au_week_number SAMPLE 5%
> SQL> /
> from au_week_number SAMPLE 5%
> *
> ERROR at line 2:
> ORA-00933: SQL command not properly ended
>
> thanks, randy

-- 
 
 
 -----------------------------
* http://pipers.hypermart.net *
 -----------------------------
Received on Tue May 14 2002 - 20:40:44 CEST

Original text of this message