Skip site navigation (1) Skip section navigation (2)

Re: No UTF8 in LC_COLLATE

From: Josh Kupershmidt <schmiddy(at)gmail(dot)com>
To: "Samaraweera, Shaminda" <shaminda(dot)samaraweera(at)navteq(dot)com>
Cc: Jens Wilke <jens(at)wilke(dot)org>, "pgsql-novice(at)postgresql(dot)org" <pgsql-novice(at)postgresql(dot)org>
Subject: Re: No UTF8 in LC_COLLATE
Date: 2010-10-16 03:56:57
Message-ID: AANLkTinTueBRXbP1O6dtUM0--vAzO3wY4aHwPHMR3g_g@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-novice
On Thu, Oct 14, 2010 at 1:37 PM, Samaraweera, Shaminda
<shaminda(dot)samaraweera(at)navteq(dot)com> wrote:
> Here is the error message I get.
>
> ERROR:  invalid byte sequence for encoding "UTF8": 0xc4c4
> CONTEXT:  COPY master_admin, line 683
>
>
> The special characters starts at line 683.

That message is telling you that you're attempting to load in a file
via COPY, and that you have your client_encoding set to UTF8, but the
file wasn't created in UTF8 encoding. You need to figure out what
encoding that file is in, and then adjust client_encoding accordingly.

> Also not really sure how to configure the system locales.
> I just see C, English_United States.1252, and Posix.
> Can somebody guide me with reference to this.

I'm not sure I understand what other problems you're having, but in
case you haven't seen it already, this page explains how Postgres
handles character encodings (as well as the client_encoding setting):
<http://www.postgresql.org/docs/current/static/multibyte.html>

Josh

In response to

pgsql-novice by date

Next:From: Bob McConnellDate: 2010-10-17 13:03:52
Subject: Overriding local encoding defaults
Previous:From: Francisco LeoveyDate: 2010-10-15 14:11:59
Subject: Re: pgstatspack reports output to file.

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group