Re: How to convert Big5 to UTF8

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: How to convert Big5 to UTF8
Дата
Msg-id 20060120135743.GA31908@svana.org
обсуждение исходный текст
Ответ на How to convert Big5 to UTF8  (Alex CS Huang <alex@smoc.com.tw>)
Список pgsql-general
On Fri, Jan 20, 2006 at 09:56:40AM +0800, Alex CS Huang wrote:
> Hi, All,
>   I create a database which encoding is UTF8, and create a table test
> create table test ( name varchar);
>   I insert a data '\244\350' encoding is Big5, I wish translate them to
> UTF8, so I use
>   insert into test values ('convert('\244\350' using big5_to_utf_8));
>   I got an error:
>   ERROR:  invalid byte sequence for encoding "UNICODE": 0xe8;
>
>   How could I do for this problem? any ideas.

How about something like:

\set encoding=big5;
insert into test values ('\244\350');

or maybe: set client_encoding=big5;

within an app.

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.

Вложения

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

Предыдущее
От: Sebastjan Trepca
Дата:
Сообщение: Re: How to fetch rows with multiple values
Следующее
От: Stephan Vollmer
Дата:
Сообщение: Creation of tsearch2 index is very slow