Re: Migration error " invalid byte sequence for encoding "UTF8": 0xff " from mysql 5.5 to postgresql 9.1 - Mailing list pgsql-general

From Kevin Grittner
Subject Re: Migration error " invalid byte sequence for encoding "UTF8": 0xff " from mysql 5.5 to postgresql 9.1
Date
Msg-id 1404220708.34556.YahooMailNeo@web122301.mail.ne1.yahoo.com
Whole thread Raw
In response to Migration error " invalid byte sequence for encoding "UTF8": 0xff " from mysql 5.5 to postgresql 9.1  (sunpeng <bluevaley@gmail.com>)
Responses Re: Migration error " invalid byte sequence for encoding "UTF8": 0xff " from mysql 5.5 to postgresql 9.1  (sunpeng <bluevaley@gmail.com>)
List pgsql-general
sunpeng <bluevaley@gmail.com> wrote:

> load data to postgresql in cmd(encoding is GBK) is WIN8:

> psql -h localhost  -d test -U postgres <  dbdata.sql
>
> I got the error:
> ERROR:  invalid byte sequence for encoding "UTF8": 0xff

If the encoding is GBK then you will get errors (or incorrect
characters) if it is read as UTF8.  Try setting the environment
variable PGCLIENTENCODING.

http://www.postgresql.org/docs/9.1/static/app-psql.html

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-general by date:

Previous
From: sunpeng
Date:
Subject: Migration error " invalid byte sequence for encoding "UTF8": 0xff " from mysql 5.5 to postgresql 9.1
Next
From: Jacob Bunk Nielsen
Date:
Subject: Next steps in debugging database storage problems?