Skip site navigation (1) Skip section navigation (2)

Re: [PATCHES] CURRENT CVS: MULTIBYTE: CANT CONNECT....

From: Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>
To: zakkr(at)zf(dot)jcu(dot)cz
Cc: pgman(at)candle(dot)pha(dot)pa(dot)us, pgsql-hackers(at)postgresql(dot)org, pgsql-patches(at)postgresql(dot)org
Subject: Re: [PATCHES] CURRENT CVS: MULTIBYTE: CANT CONNECT....
Date: 2001-09-10 06:50:46
Message-ID: 20010910155046Q.t-ishii@sra.co.jp (view raw or flat)
Thread:
Lists: pgsql-bugspgsql-hackerspgsql-patches
> > Why? set_default_client_encoding does the job anyway.
> 
>  Here can't be used static default encoding as for DatabaseEncoding, because
> typical code is
> 
>  if (!ClientEncoding)
> 	/* ...means "if user doesn't set itself client 
> 	 * encoding by SET command"
> 	 */  
> 	ClientEncoding = DatabaseEncoding;
> 
>  and if you set anywhere before this as default 
> ClientEncoding = &pg_enc2name_tbl[ PG_SQL_ASCII ]; the ClientEncoding will
> always TRUE and always SQL_ASCII and the only way is change it by 'SET
> CLIENT_ENCODING' command. But we don't want it, wanted is after connection 
> set as default ClientEncoding same encoding as actual DabaseEncoding. 

Don't worry about that. Before anything user could do, postgres's
start up procedure sets the appropreate encoding to ClientEncoding
variable.

Also please note that "wanted is after connection set as default
ClientEncoding same encoding as actual DabaseEncoding" is not
corrent. The ClientEncoding might be set differently if
PGCLIENTENCODING is set before postmaster starts up.
--
Tatsuo Ishii


In response to

Responses

pgsql-hackers by date

Next:From: Karel ZakDate: 2001-09-10 07:13:00
Subject: Re: [PATCHES] CURRENT CVS: MULTIBYTE: CANT CONNECT....
Previous:From: Tatsuo IshiiDate: 2001-09-10 06:40:16
Subject: COMMENT ON

pgsql-bugs by date

Next:From: Karel ZakDate: 2001-09-10 07:13:00
Subject: Re: [PATCHES] CURRENT CVS: MULTIBYTE: CANT CONNECT....
Previous:From: Karel ZakDate: 2001-09-10 06:27:52
Subject: Re: [PATCHES] CURRENT CVS: MULTIBYTE: CANT CONNECT....

pgsql-patches by date

Next:From: Karel ZakDate: 2001-09-10 07:13:00
Subject: Re: [PATCHES] CURRENT CVS: MULTIBYTE: CANT CONNECT....
Previous:From: Karel ZakDate: 2001-09-10 06:27:52
Subject: Re: [PATCHES] CURRENT CVS: MULTIBYTE: CANT CONNECT....

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group