Re: Database encoding

From: valgog <valgog(at)gmail(dot)com>
To: pgsql-admin(at)postgresql(dot)org
Subject: Re: Database encoding
Date: 2008-09-04 07:35:02
Message-ID: 0302d94a-7a8e-46cc-bc47-c6b02623c38c@r15g2000prd.googlegroups.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Sep 3, 3:40 pm, a(dot)(dot)(dot)(at)personal(dot)net(dot)py ("Anibal David Acosta") wrote:
> Hello, I have a postgresql installed with encoding "WIN1252".
>
> But I need to create a DB with LATIN1 encoding, when I try I got the error:
> "Encoding Latin1 does not match server's locale Spanish_Spain.1252. The
> servers's LC_CTYPE setting require encoding WIN1252
>
> Is possible to change the server encoding to LATIN1?
>
> Thanks for your help!

You should use the same encoding for your DB instance as you used when
creating a DB with initdb. Usually it makes sense to always use UTF8
as your encoding... in case you will need some non-LATIN1
characters... you can check which encoding was used when creating a DB
with show lc_ctype...

Regards,

-- Valentine

P.S.: there are many posts related to that issue. You can look up a
BUG mailing list for collate and encoding.

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Carol Walter 2008-09-04 13:24:34 Database Conversion
Previous Message Larry Rosenman 2008-09-03 20:17:07 Re: PostgreSQL and ZFS