Igor Korot <[email protected]> writes:
> I added the following code in my app:
> res = PQexec( m_db, "SHOW client_encoding" );
> auto value = PQgetvalue( res, 0, 0 );
> PQclear( res );
> and the value of the "value" variable is "UTF8".
Okay ...
> The exact error message is:
> ERROR: invalid byte sequence for encoding UTF8: 0xdf
> CONTEXT: unnamed portal parameter $1
> on the INSERT.
client_encoding governs both the encoding that the server will
send, and the encoding that it expects to receive. You are
sending a parameter string that is not valid UTF8.
regards, tom lane