proposal: UTF8 to_ascii function

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема proposal: UTF8 to_ascii function
Дата
Msg-id 162867790808110039xd20a016oac912e39343e7514@mail.gmail.com
обсуждение исходный текст
Ответы Re: proposal: UTF8 to_ascii function  (Andrew Dunstan <andrew@dunslane.net>)
Список pgsql-hackers
Hello,

combination functions to_ascii and convert_to is broken now. Problem
is in convert_to function. It doesn't support 8bit output encoding.

Current workaround:

CREATE FUNCTION to_ascii(bytea, name)
RETURNS text AS 'to_ascii_encname' LANGUAGE internal;

SELECT to_ascii(convert_to('Příliš žlutý kůň', 'latin2'),'latin2');

I don't expect column collate for 8.4, so we need to have workable
to_ascii function.

I propose function to_ascii(text, name) that internally convert text
from utf8 encoding when it's necessary.

Regards
Pavel Stehule

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

Предыдущее
От: Zdenek Kotala
Дата:
Сообщение: Proposal: PageLayout footprint
Следующее
От: "Heikki Linnakangas"
Дата:
Сообщение: Re: Proposal: PageLayout footprint