Re: character_not_in_repertoire vs. untranslatable_character

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: character_not_in_repertoire vs. untranslatable_character
Дата
Msg-id 3701.1457304992@sss.pgh.pa.us
обсуждение исходный текст
Ответ на character_not_in_repertoire vs. untranslatable_character  (Chapman Flack <chap@anastigmatix.net>)
Список pgsql-hackers
Chapman Flack <chap@anastigmatix.net> writes:
> So there's an ISO error 22021 "character not in repertoire" and
> a PostgreSQL error 22P05 "untranslatable character" that seem
> very similar.

> If I look in backend/utils/mb/wchar.c, it looks as if PostgreSQL
> uses the first for the case of a corrupted encoding (bytes that
> can't be decoded to a character at all), and the second for the
> case of a valid character that isn't available in a conversion's
> destination encoding.

Yeah, that's the intended distinction I believe, though I would not
want to swear that we've been 100% consistent.  22021 means "this
character is bad in isolation", AFAICT, so it didn't seem appropriate
for the conversion scenario.
        regards, tom lane



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

Предыдущее
От: Thom Brown
Дата:
Сообщение: Re: The plan for FDW-based sharding
Следующее
От: Thomas Munro
Дата:
Сообщение: Re: Proposal: "Causal reads" mode for load balancing reads without stale data