Thread: using initcap() for the French charater

using initcap() for the French charater

From
Emi Lu
Date:
Hello,

I am having a problem of using initcap() for the French charater.

. create table test (id varchar(3));
. insert into test values('É');
. select initcap(id) from test;

*Got ERROR:*  invalid multibyte character for locale
HINT:  The server's LC_CTYPE locale is probably incompatible with the
database encoding.


By the way, both my client and server encoding are  "UNICODE".

Ying



Re: using initcap() for the French charater

From
Tom Lane
Date:
Emi Lu <emilu@encs.concordia.ca> writes:
> *Got ERROR:*  invalid multibyte character for locale
> HINT:  The server's LC_CTYPE locale is probably incompatible with the
> database encoding.

> By the way, both my client and server encoding are  "UNICODE".

Sounds like you initdb'd using a locale that expects some other encoding
than UTF8.

            regards, tom lane