Re: compute_query_id
От | Julien Rouhaud |
---|---|
Тема | Re: compute_query_id |
Дата | |
Msg-id | 20210617153441.klssqpnou77zu5bd@nol обсуждение исходный текст |
Ответ на | Re: compute_query_id (Vijaykumar Jain <vijaykumarjain.github@gmail.com>) |
Список | pgsql-general |
On Thu, Jun 17, 2021 at 08:57:02PM +0530, Vijaykumar Jain wrote: > > test=# show log_line_prefix; > log_line_prefix > -------------------------------- > [timestamp=%t] [query_id=%Q] : > (1 row) > > test=# show compute_query_id; > compute_query_id > ------------------ > on > (1 row) > > test=# show log_statement; > log_statement > --------------- > all > (1 row) > > ************************************* corrects myself > ..... ok now it works, when i set log_min_duration_statement =0 to log > all statements. > > test=# show log_min_duration_statement; > log_min_duration_statement > ---------------------------- > 0 > (1 row) Yes, unfortunately log_statements is not compatible with compute_query_id. This is documented at https://www.postgresql.org/docs/devel/runtime-config-logging.html#GUC-LOG-LINE-PREFIX: > The %Q escape always reports a zero identifier for lines output by > log_statement because log_statement generates output before an identifier can > be calculated, including invalid statements for which an identifier cannot be > calculated.
В списке pgsql-general по дате отправления: