Re: gaussian distribution pgbench - Mailing list pgsql-hackers

From KONDO Mitsumasa
Subject Re: gaussian distribution pgbench
Date
Msg-id 5313FEFA.3010802@lab.ntt.co.jp
Whole thread Raw
In response to Re: gaussian distribution pgbench  (Fabien COELHO <coelho@cri.ensmp.fr>)
Responses Re: gaussian distribution pgbench  (Fabien COELHO <coelho@cri.ensmp.fr>)
List pgsql-hackers
(2014/03/02 22:32), Fabien COELHO wrote:
>> Alvaro Herrera <alvherre@2ndquadrant.com> writes:
>>> Seems that in the review so far, Fabien has focused mainly in the
>>> mathematical properties of the new random number generation.  That seems
>>> perfectly fine, but no comment has been made about the chosen UI for the
>>> feature.
>>>  Per the few initial messages in the thread, in the patch as submitted you ask
>>> for a gaussian random number by using \setgaussian, and exponential via
>>> \setexp.  Is this the right UI?
> I thought it would be both concise & clear to have that as another form of \set*.
Yeah, but we got only two or three? concise. So I agree with discussing about UI.

> There is an additional argument expected. That would make:
>
>    \setrandom foo 1 10 [uniform]
>    \setrandom foo 1 :size gaussian 3.6
>    \setrandom foo 1 100 exponential 7.2
It's good design. I think it will become more low overhead at part of parsing in 
pgbench, because comparison of strings will be redeced(maybe). And I'd like to 
remove [uniform], beacause we have to have compatibility for old scripts, and 
random function always gets uniform distribution in common sense of programming.

However, new grammer is little bit long in user script. It seems trade-off that 
are visibility of scripts and user writing cost.

Regards,
--
Mitsumasa KONDO
NTT Open Source Software Center



pgsql-hackers by date:

Previous
From: Kyotaro HORIGUCHI
Date:
Subject: Re: Hot standby doesn't come up on some situation.
Next
From: Andrew Dunstan
Date:
Subject: Re: Review: Patch FORCE_NULL option for copy COPY in CSV mode