BUG #5221: errors converting string to utf8 - Mailing list pgsql-bugs

From DM
Subject BUG #5221: errors converting string to utf8
Date
Msg-id 200912011136.nB1Ba8CR022772@wwwmaster.postgresql.org
Whole thread Raw
Responses Re: BUG #5221: errors converting string to utf8  (Craig Ringer <craig@postnewspapers.com.au>)
List pgsql-bugs
The following bug has been logged online:

Bug reference:      5221
Logged by:          DM
Email address:      dmedri@ciseonweb.it
PostgreSQL version: 8.2 / 8.4
Operating system:   linux ubuntu 9.10
Description:        errors converting string to utf8
Details:

I'm using 2 version of pg (8.2, 8.4).

On 8.2:

select convert('Vall\xe9e','LATIN1','UTF8');

convert this string without any kind of error.


On 8.4:

select convert('Vall\xe9e','LATIN1','UTF8');

i receive these messages:

WARNING:  nonstandard use of escape in a string literal
RIGA 1: select convert('Vall\xe9e','LATIN1','UTF8');
                       ^
HINT: Use the escape string syntax for escapes, e.g., E'\r\n'.
ERROR:  invalid byte sequence for encoding "UTF8": 0xe965
HINT: This error can also happen if the byte sequence does not match the
encoding expected by the server, which is controlled by "client_encoding".


client charset: utf8
server charset: utf8

pgsql-bugs by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: Assertion failure with a subtransaction and cursor
Next
From: Craig Ringer
Date:
Subject: Re: BUG #5221: errors converting string to utf8