On Fri, 2026-09-25 at 09:32 +0000, PG Doc comments form wrote:
> Page: https://www.postgresql.org/docs/18/index.html
> 
> I noticed, that it not documented anywhere what log_line_prefix will do, if
> log_destination = 'jsonlog' (Or CSV). From my tests it seems it is ignored
> and does nothing. But we weren't sure and would be helpful to have this
> documented.

True; here is a patch.

Yours,
Laurenz Albe
From 66a669efb0d65a9016d90aa49d7329d709b3776a Mon Sep 17 00:00:00 2001
From: Laurenz Albe <[email protected]>
Date: Fri, 25 Sep 2026 17:04:38 +0200
Subject: [PATCH v1] Doc: no log_line_prefix in csvlog or jsonlog
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

The documentation didn't make clear that "log_line_prefix" is
not output if "log_destination" is "csvlog" or "jsonlog".

Author: Laurenz Albe <[email protected]>
Reported-by: Michael Schönitzer <[email protected]>
Discussion: https://postgr.es/m/[email protected]
---
 doc/src/sgml/config.sgml | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/doc/src/sgml/config.sgml b/doc/src/sgml/config.sgml
index 0165eb9ec02..f277d311232 100644
--- a/doc/src/sgml/config.sgml
+++ b/doc/src/sgml/config.sgml
@@ -8224,7 +8224,8 @@ local0.*    /var/log/postgresql
       <listitem>
        <para>
          This is a <function>printf</function>-style string that is output at the
-         beginning of each log line.
+         beginning of each log line, except when <varname>log_destination</varname>
+         is <literal>csvlog</literal> or <literal>jsonlog</literal>.
          <literal>%</literal> characters begin <quote>escape sequences</quote>
          that are replaced with status information as outlined below.
          Unrecognized escapes are ignored. Other
-- 
2.55.0

Reply via email to