diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2020-12-20 13:37:25 -0500 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2020-12-20 13:37:25 -0500 |
commit | 3989fdab48d937b448198e9886bb07c6027b00ca (patch) | |
tree | db2225e9b086f3ae9a79ac162116cb4ee7e575c7 | |
parent | ba04cedf1d262f3d7dfe6950b13a7ed1d80a9502 (diff) | |
download | postgresql-3989fdab48d937b448198e9886bb07c6027b00ca.tar.gz postgresql-3989fdab48d937b448198e9886bb07c6027b00ca.zip |
Doc: improve description of pgbench script weights.
Point out the workaround to be used if you want to write a script
file name that includes "@". Clean up the text a little.
Fabien Coelho, additional wordsmithing by me
Discussion: https://postgr.es/m/1c4e81550d214741827a03292222db8d@G08CNEXMBPEKD06.g08.fujitsu.local
-rw-r--r-- | doc/src/sgml/ref/pgbench.sgml | 34 |
1 files changed, 22 insertions, 12 deletions
diff --git a/doc/src/sgml/ref/pgbench.sgml b/doc/src/sgml/ref/pgbench.sgml index b32b962a606..7f658848df8 100644 --- a/doc/src/sgml/ref/pgbench.sgml +++ b/doc/src/sgml/ref/pgbench.sgml @@ -346,15 +346,19 @@ pgbench <optional> <replaceable>options</replaceable> </optional> <replaceable>d <term><option>--builtin</option>=<replaceable>scriptname[@weight]</replaceable></term> <listitem> <para> - Add the specified built-in script to the list of executed scripts. - An optional integer weight after <literal>@</literal> allows to adjust the - probability of drawing the script. If not specified, it is set to 1. + Add the specified built-in script to the list of scripts to be executed. Available built-in scripts are: <literal>tpcb-like</literal>, <literal>simple-update</literal> and <literal>select-only</literal>. Unambiguous prefixes of built-in names are accepted. - With special name <literal>list</literal>, show the list of built-in scripts + With the special name <literal>list</literal>, show the list of built-in scripts and exit immediately. </para> + <para> + Optionally, write an integer weight after <literal>@</literal> to + adjust the probability of selecting this script versus other ones. + The default weight is 1. + See below for details. + </para> </listitem> </varlistentry> @@ -408,10 +412,16 @@ pgbench <optional> <replaceable>options</replaceable> </optional> <replaceable>d <term><option>--file=</option><replaceable>filename[@weight]</replaceable></term> <listitem> <para> - Add a transaction script read from <replaceable>filename</replaceable> to - the list of executed scripts. - An optional integer weight after <literal>@</literal> allows to adjust the - probability of drawing the test. + Add a transaction script read from <replaceable>filename</replaceable> + to the list of scripts to be executed. + </para> + <para> + Optionally, write an integer weight after <literal>@</literal> to + adjust the probability of selecting this script versus other ones. + The default weight is 1. + (To use a script file name that includes an <literal>@</literal> + character, append a weight so that there is no ambiguity, for + example <literal>filen@me@1</literal>.) See below for details. </para> </listitem> @@ -859,10 +869,10 @@ pgbench <optional> <replaceable>options</replaceable> </optional> <replaceable>d <para> <application>pgbench</application> executes test scripts chosen randomly from a specified list. - They include built-in scripts with <option>-b</option> and - user-provided custom scripts with <option>-f</option>. - Each script may be given a relative weight specified after a - <literal>@</literal> so as to change its drawing probability. + The scripts may include built-in scripts specified with <option>-b</option> + and user-provided scripts specified with <option>-f</option>. + Each script may be given a relative weight specified after an + <literal>@</literal> so as to change its selection probability. The default weight is <literal>1</literal>. Scripts with a weight of <literal>0</literal> are ignored. </para> |