logo       
Google Custom Search
    AddThis Social Bookmark Button
-->

Re: Coding when open conection (+- Solved): msg#00061

Subject: Re: Coding when open conection (+- Solved)
Federico Di Gregorio escribió:
Il giorno ven, 10/03/2006 alle 19.35 +0100, Oswaldo Hernández ha
scritto:
[snip]

I forced a conversion of the postgresql error string from latin1 to
unicode and now works fine in  the connect moment and after of
client_encoding.


I'm glad you solved it. I'd like to solve this in psycopg too but if
PostgreSQL let you use 2 different encodings (for messages and data) I
don't see any viable solution. :/


The data works fine for me without need of input or output conversion, the problem was only in the messages.

The last week I spent a lot of time testing encodings between wx, python and 
postgresql.
Initially I have python with defalut encoding latin1, postgresql with latin1 and wx unicode version, there no problem with messages, but I have data problems with some characters ('€' Euro char).
The final composite that apparently works fine whith data was putting UTF8 in 
all.
But then ocurr the message problem.

Until now, I ignore the double encoding and i think that it's a big problem.

May be Postgresql should retrieve the messages in the same encoding of the data, converting it if it be need. Or at least include a new instruction to inform the message encoding, same as 'show database_encoding' or 'show client encoding'. Without this then programmer never konws how convert the messages.

Regards
--
*****************************************
Oswaldo Hernández
oswaldo-aXkDUzFGsCcxAGwisGp4zA@xxxxxxxxxxxxxxxx
*****************************************


<Prev in Thread] Current Thread [Next in Thread>