Re: Unicode upper() bug still present - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Unicode upper() bug still present
Date
Msg-id 1794.1066655148@sss.pgh.pa.us
Whole thread Raw
In response to Re: Unicode upper() bug still present  (Hannu Krosing <hannu@tm.ee>)
List pgsql-hackers
Hannu Krosing <hannu@tm.ee> writes:
>> It's been suggested that we could use <wctype.h> where available.
>> However there are a bunch of issues that would have to be solved to make
>> that happen.  (How do we convert between the database character encoding 
>> and the wctype representation?  

> How do we do it for sorting ?

We don't --- strcoll() handles it all internally.

> It seems inconsistent that we do use locale-aware sorts but not
> upper/lower.

We do have locale-aware upper/lower ... but only in single-byte
encodings.  I think it works for the 7-bit-ASCII subset of multibyte
encodings, too.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Hannu Krosing
Date:
Subject: Re: Unicode upper() bug still present
Next
From: Tom Lane
Date:
Subject: Re: Unicode upper() bug still present