pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Eugene Podshivalov <yaugenka@gmail.com>
Cc: Bruce Momjian <bruce@momjian.us>
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #15772: Some messages in log files are in ANSI encoding while server encoding is UTF8
Date: Thu, 18 Apr 2019 12:20:56 -0400
Message-ID: <12140.1555604456@sss.pgh.pa.us> (raw)
In-Reply-To: <20190418160116.GA13165@alvherre.pgsql>
References: <20190418160116.GA13165@alvherre.pgsql>

Alvaro Herrera <alvherre@2ndquadrant.com> writes:
> I suppose you have databases with the single-byte encoding amidst your
> UTF8 ones.  AFAIK the log file registers the log entries in the same
> encoding that the database uses.  Different databases can use different
> encodings.

> That's pretty broken, but it's how it is.

Yeah, and it's not easy to improve on.  If we tried to convert all
log messages to the same encoding, which one would that be?
(Please, no nonsense about UTF8 being a universal solution.
The Japanese don't think so, for instance.)

Also, what do you do if you get an encoding conversion failure?

That's even before you get into implementation-dependent problems,
like what to do early in process startup before the encoding
conversion machinery is operational.

A more realistic idea might be to have separate log files for
different encodings, though that has a bunch of management issues
to solve as well.

			regards, tom lane





view thread (8+ messages)  latest in thread

Message-ID: <12140.1555604456@sss.pgh.pa.us>
Permalink:  ../12140.1555604456@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/12140.1555604456@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, alvherre@2ndquadrant.com, yaugenka@gmail.com, bruce@momjian.us
  Subject: Re: BUG #15772: Some messages in log files are in ANSI encoding while server encoding is UTF8
  In-Reply-To: <12140.1555604456@sss.pgh.pa.us>
  References: <20190418160116.GA13165@alvherre.pgsql> <12140.1555604456@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox