Re: change encoding

From: "J(dot) Manuel Velasco - UBILIBET" <tech(at)ubilibet(dot)com>
To: "J(dot) Manuel Velasco - UBILIBET" <tech(at)ubilibet(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: change encoding
Date: 2008-05-14 08:33:41
Message-ID: 482AA3E5.60103@ubilibet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi Martijn,

Thank you very much for reply. It has worked perfectly.

Have a good life,

All beings be happy

Martijn van Oosterhout escribió:
> On Tue, May 13, 2008 at 05:37:27PM +0200, J. Manuel Velasco - UBILIBET wrote:
>
>> I have the idea to create the database and the role and then load the
>> pg_dump result from the other database. The old databse has encoding
>> LATIN2 so I try to create with this encoding and I get the message(*):
>> ERROR: la codificacion LATIN2 no coincide con la configuracion regional
>> del servidor es_es.UTF8
>> DETAIL: la configuracion regional LC_TYPE del servidor requiere la
>> codificacion UTF8
>>
>> The command I try is:
>> postgres=# create database gestio_sl with template=template0 owner
>> webadmin encoding='latin2';
>>
>
> My point was, the database does not have to be in LATIN2 (so remove
> the encoding=latin2 part). If you leave the database in UTF-8 but do
> the command I suggested
>
>
>>> ALTER DATABASE foo SET client_encoding=latin2;
>>>
>
> Then everything will work like it used to and you will be able to load
> your dump without problems.
>
> If you really truly want to change the encoding you have to
> reinitialise the whole cluster. Delete the directory and reinitdb.
>
> Have a nice day,
>

--

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Volkan YAZICI 2008-05-14 08:33:56 Re: Affected # of Rows After TRIGGER/RULE Return
Previous Message Gerald Quimpo 2008-05-14 08:07:04 Re: Affected # of Rows After TRIGGER/RULE Return