You should be able to use it if you use a current version of MonetDb instead
of the stable .

Any SQL query you write can end with the SAMPLE clause -  this functionality
is there already. If you find any bugs or have more ideas about the usage of
that operator please let me know since it is still experimental and just
introduced:)

On Thu, Sep 22, 2011 at 3:03 PM, Roberto Cornacchia <
[email protected]> wrote:

> I see, great.
> I was tricked by "greater than 1" in "where s if is an integer greater than
> 1".
> Perhaps that should go then.
>
> No pressure, just to have an idea, will this be usable soon as a full SQL
> functionality?
> Just today I happen to need it :)
> Cheers, Roberto
>
>
> On Thu, Sep 22, 2011 at 14:34, Lefteris <[email protected]> wrote:
>
>>
>> SAMPLE 1 will mean 1 tuple
>>
>> and
>>
>> SAMPLE 1.0 will mean 100%
>>
>> it it is an integer is number of tuples and if it is a double is the
>> fraction of the total size of results
>>
>> On Thu, Sep 22, 2011 at 1:37 PM, Roberto Cornacchia <
>> [email protected]> wrote:
>>
>>> + * A new SQL operator has been added to support sampling the result of a
>>>> query.
>>>> + * The syntax for sampling is:
>>>> + * SELECT ... FROM ... WHERE ... SAMPLE s
>>>> + *
>>>> + * where s if is an integer greater than 1, it defines the number of
>>>> rows to be
>>>> + * in the sample. If s is a double between [0.0,1.0] the it refers to
>>>> the
>>>> + * percentage of the result to be sampled. That is if s=0.3 then the
>>>> sample
>>>> + * will be 30% the size of the query result.
>>>>
>>>
>>> Does this mean that it is not possible to select 1 random tuple? ("SAMPLE
>>> 1" would mean 100%)
>>>
>>> Roberto
>>>
>>> _______________________________________________
>>> Checkin-list mailing list
>>> [email protected]
>>> http://mail.monetdb.org/mailman/listinfo/checkin-list
>>>
>>>
>>
>> _______________________________________________
>> Checkin-list mailing list
>> [email protected]
>> http://mail.monetdb.org/mailman/listinfo/checkin-list
>>
>>
>
> _______________________________________________
> Checkin-list mailing list
> [email protected]
> http://mail.monetdb.org/mailman/listinfo/checkin-list
>
>
_______________________________________________
Checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to