Re: current breakage with PGCLIENTENCODING - Mailing list pgsql-hackers

From Tom Lane
Subject Re: current breakage with PGCLIENTENCODING
Date
Msg-id 22758.1051420434@sss.pgh.pa.us
Whole thread Raw
In response to current breakage with PGCLIENTENCODING  (Tatsuo Ishii <t-ishii@sra.co.jp>)
Responses Re: current breakage with PGCLIENTENCODING  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tatsuo Ishii <t-ishii@sra.co.jp> writes:
> As you can see, the result of "show client_encoding;" and "select
> pg_client_encoding();" do not match.

Weird, it works fine for me:

$ PGCLIENTENCODING=SJIS psql regression
Welcome to psql 7.4devel, the PostgreSQL interactive terminal.

Type:  \copyright for distribution terms      \h for help with SQL commands      \? for help on internal slash commands
    \g or terminate with semicolon to execute query      \q to quit
 

regression=# \encoding
SJIS
regression=# show client_encoding;client_encoding
-----------------SJIS
(1 row)

regression=# select pg_client_encoding();pg_client_encoding
--------------------SJIS
(1 row)

I would not have been real surprised to hear that psql's \encoding is
out of sync, but it *does* surprise me that "show client_encoding" might
not match pg_client_encoding().  I would think those are looking at the
same backend state variable.  Any theory how that could happen?
        regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Array access to type "name"
Next
From: Tom Lane
Date:
Subject: Re: current breakage with PGCLIENTENCODING