Re: ERROR: could not convert UTF-8 character 0x00ef to ISO8859-1 possiblesolution
От | Anders Hermansen |
---|---|
Тема | Re: ERROR: could not convert UTF-8 character 0x00ef to ISO8859-1 possiblesolution |
Дата | |
Msg-id | 20050428071833.GB13436@online.no обсуждение исходный текст |
Ответ на | Re: ERROR: could not convert UTF-8 character 0x00ef to ISO8859-1 possiblesolution (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: ERROR: could not convert UTF-8 character 0x00ef to ISO8859-1 possiblesolution
|
Список | pgsql-jdbc |
* Tom Lane (tgl@sss.pgh.pa.us) wrote: > Looking at the source code, it's clear that it's reporting just the > first byte of the sequence; the 00 is redundant and probably shouldn't > be in the message. Yes the error message can be a bit confusing. I investigated a error I got when using psql. I did a select and got the message: "ERROR: could not convert UTF-8 character 0x00e2 to ISO8859-1" When looking at the database dump the byte sequence is 0xE2 0x80 0x93, which is valid UTF-8 (U+2013 EN DASH), but can not be converted because the character is not found in ISO-8859-1. If I start up a UTF-8 xterm and psql with UNICODE encoding, then everything works as expected. > There seem to be two possibilities: either there is a valid 3-byte > UTF8 character, which cannot be converted to LATIN1; or the alleged > UTF8 data isn't really UTF8 at all. Yes. Maybe the error messages can be changed so that what actually went wrong is more clear? And possibly printing the whole 3-byte sequence? Anders Hermansen
В списке pgsql-jdbc по дате отправления: