Re: gaussian distribution pgbench - Mailing list pgsql-hackers

From Fabien COELHO
Subject Re: gaussian distribution pgbench
Date
Msg-id alpine.DEB.2.10.1403131958460.4831@sto
Whole thread Raw
In response to Re: gaussian distribution pgbench  (Fujii Masao <masao.fujii@gmail.com>)
Responses Re: gaussian distribution pgbench
List pgsql-hackers
> We should do the same discussion for the UI of command-line option? The 
> patch adds two options --gaussian and --exponential, but this UI seems 
> to be a bit inconsistent with the UI for \setrandom.
> Instead, we can use something like --distribution=[uniform | gaussian | 
> exponential].

Hmmm. That is possible, obviously.

Note that it does not need to resort to a custom script, if one can do 
something like "--define=exp_threshold=5.6". If so, maybe one simpler 
named variable could be used, say "threshold", instead of separate names 
for each options.

However there is a catch: currently the option allows to check that the 
threshold is large enough so as to avoid loops in the generator. So this 
mean moving the check in the generator, and doing it over and over. 
Possibly this is a good idea, because otherwise a custom script could 
circumvent the check. Well, the current status is that the check can be 
avoided with --define...

Also, a shorter possibly additional name, would be nice, maybe something 
like: --dist=exp|gauss|uniform? Not sure. I like long options not to be 
too long.

-- 
Fabien.



pgsql-hackers by date:

Previous
From: Alexander Korotkov
Date:
Subject: Re: GIN improvements part2: fast scan
Next
From: Robert Haas
Date:
Subject: Re: Replication slots and footguns