Re: UTF8 with BOM support in psql

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: UTF8 with BOM support in psql
Дата
Msg-id 1258477390.10724.25.camel@fsopti579.F-Secure.com
обсуждение исходный текст
Ответ на Re: UTF8 with BOM support in psql  (Itagaki Takahiro <itagaki.takahiro@oss.ntt.co.jp>)
Ответы Re: UTF8 with BOM support in psql
Список pgsql-hackers
On tis, 2009-11-17 at 09:31 +0900, Itagaki Takahiro wrote:
> Peter Eisentraut <peter_e@gmx.net> wrote:
> 
> > OK, I think the consensus here is:
> > - Eat BOM at beginning of file (as you implemented)
> > - Only when client encoding is UTF-8 --> please fix that
> 
> Are they AND condition? If so, this patch will be useless.
> Please remember \encoding or SET client_encoding appear
> *after* BOM at beginning of file.

Presumably, if you have editors throwing in BOM marks without asking,
you have an environment where either

a) You can set the client encoding to UTF8 in the environment, so it
applies by default, or

b) The server encoding is UTF8, so the client encoding will default to
that.

Together, that should cover a lot of cases.  Not perfect, but far from
useless.



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

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Re: plpythonu DO support (inline call handler)
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: UTF8 with BOM support in psql