Re: Problem with langage encoding

Поиск
Список
Период
Сортировка
От Raymond O'Donnell
Тема Re: Problem with langage encoding
Дата
Msg-id 492D660B.5050208@iol.ie
обсуждение исходный текст
Ответ на Problem with langage encoding  ("Ronald Vyhmeister" <rvyhmeister@gmail.com>)
Ответы Re: Problem with langage encoding  ("Ronald Vyhmeister" <rvyhmeister@gmail.com>)
Список pgsql-general
On 26/11/2008 14:40, Ronald Vyhmeister wrote:

> The problem is that the database is UTF8, and it won't let me use the
> convert_to function because it says that the characters don't exist... What
> I need to do is to pull the UTF8 from the database, tell postgres that it's
> 8859-1, and then convert it to WIN1251... How?

If the DB is in UTF8, you ought to be able to issue

  set client_encoding to 'WIN1251'

after connection, and the conversion happens automatically. See:

  http://www.postgresql.org/docs/8.3/static/multibyte.html#AEN27483

HTH,

Ray.


------------------------------------------------------------------
Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland
rod@iol.ie
Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals
------------------------------------------------------------------

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

Предыдущее
От: "Ronald Vyhmeister"
Дата:
Сообщение: Problem with langage encoding
Следующее
От: "Ronald Vyhmeister"
Дата:
Сообщение: Re: Problem with langage encoding