Re: convert(... using windows_1251_to_utf8) - works on cli, but not in a c prog. - Mailing list pgsql-general

From Alvaro Herrera
Subject Re: convert(... using windows_1251_to_utf8) - works on cli, but not in a c prog.
Date
Msg-id 20061224000125.GC25135@alvh.no-ip.org
Whole thread Raw
In response to Re: convert(... using windows_1251_to_utf8) - works on cli, but not in a c prog.  ("Alexander Farber" <alexander.farber@gmail.com>)
Responses Re: convert(... using windows_1251_to_utf8) - works on cli, but not in a c prog.  ("Alexander Farber" <alexander.farber@gmail.com>)
List pgsql-general
Alexander Farber wrote:
> I started to prepare a test case and realized I had a bug.
> So convert() works for me, sorry for my previous message!

In any case, it's probably saner if you SET client_encoding at the start
of the session instead of using convert() everywhere.  The
server_encoding should be correctly set to Win1251 though!  (Using
SQL_ASCII, while not technically incorrect, is probably not doing you
any favor).

--
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

pgsql-general by date:

Previous
From: "Alexander Farber"
Date:
Subject: Re: convert(... using windows_1251_to_utf8) - works on cli, but not in a c prog.
Next
From: Tom Lane
Date:
Subject: Re: [ADMIN] OUTER JOIN IS SLOW