Re: pgbench - minor doc improvements

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: pgbench - minor doc improvements
Дата
Msg-id alpine.DEB.2.20.1607110710410.12659@sto
обсуждение исходный текст
Ответ на Re: pgbench - minor doc improvements  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-hackers
Hello Michaël,

>> Minor pgbench documentation improvements so that the description is more
>> precise:
>>
>>  - a pgbench script may not contain SQL commands, it only needs not to be
>>    empty.
>
> Halfly true as far as I recall. This works and generates two queries:
> SELECT 1; \set two 3

Maybe it used to work, but not anymore:
  client 0 aborted in state 0: ERROR:  syntax error at or near "\"  LINE 1: SELECT 1 ; \set two 3

>>  - point out explicitely variable setting meta commands.
>>  - the formula is short enough to fit on a line.
>
> <literallayout>
> -f(x) = PHI(2.0 * parameter * (x - mu) / (max - min + 1)) /
> -       (2.0 * PHI(parameter) - 1)
> +f(x) = PHI(2.0 * parameter * (x - mu) / (max - min + 1)) / (2.0 *
> PHI(parameter) - 1)
> At full-length this is 85 characters.

I agree on principle, however the issue is the "literal layout", the line 
is also broken in the resulting HTML and it looks pretty strange there:
  https://www.postgresql.org/docs/devel/static/pgbench.html

> But I agree that it is more readable to put that into a single line. Now 
> we could as well trick the limit by using "param" instead of 
> "parameter".

ISTM that it would mean changing the text in a dozen places to be 
consistent, and it would not necessary be an improvement in some of those 
places... So I'm hesitant to follow on that suggestion. For me the "under 
80 column" rule cannot really apply on a "literal layout" block.

-- 
Fabien.

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Craig Ringer
Дата:
Сообщение: Re: Disable WAL completely - Performance and Persistency research
Следующее
От: Craig Ringer
Дата:
Сообщение: Re: Fix Error Message for allocate_recordbuf() Failure