I think it is an expected result.
As far as I understand it, LC_ALL determines the collation/sorting rule, and
unicode allows you to store and retrieve multibytes character which has nothing
to do with the soring rules.
kathy
> X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org
> Date: Sat, 20 Sep 2003 22:53:54 +0200
> From: Andreas Hinz <news3@winopticc.dk>
> To: pgsql-general@postgresql.org
> Subject: Re: [GENERAL] 'order by' does "wrong" with unicode-chars (german
umlauts)
> X-Virus-Scanned: by amavisd-new at postgresql.org
> X-Mailing-List: pgsql-general
> X-AntiAbuse: This header was added to track abuse, please include it with any
abuse report
> X-AntiAbuse: Primary Hostname - noon.pghoster.com
> X-AntiAbuse: Original Domain - sun.com
> X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
> X-AntiAbuse: Sender Address Domain - postgresql.org
> Content-Transfer-Encoding: 8bit
> X-MIME-Autoconverted: from quoted-printable to 8bit by amon.Central.Sun.COM id
h8M2O1c23732
>
> Sat, 20 Sep 2003 18:39:35 +0200
> skrev pilsl@goldfisch.at (peter pilsl):
>
> > It makes no difference if I use a database with encoding unicode:
> >
>
> ah@ahb:~$ LC_ALL=da_DK initdb
> ah@ahb:~$ su postgres -c "/usr/local/pgsql/bin/createuser -ad ah"
> ah@ahb:~$ createdb ah
> ah@ahb:~$ psql ah
>
> ah=# \l
>
> List of databases
> Name | Owner | Encoding
> -----------+----------+-----------
> ah | ah | SQL_ASCII
>
>
> ah=# show client_encoding;
>
> client_encoding
> -----------------
> SQL_ASCII
> (1 row)
>
>
> CREATE TABLE test (f1 varchar);
>
> INSERT INTO test VALUES ('A');
> INSERT INTO test VALUES ('B');
> INSERT INTO test VALUES ('AA');
> INSERT INTO test VALUES ('Æ');
> INSERT INTO test VALUES ('Å');
> INSERT INTO test VALUES ('Ø');
> INSERT INTO test VALUES ('Ä');
> INSERT INTO test VALUES ('Ö');
> INSERT INTO test VALUES ('Ü');
>
> SELECT * FROM test ORDER BY f1;
>
> t
> ----
> A
> B
> Ü
> Æ
> Ä
> Ø
> Ö
> Å
> AA
> (9 rows)
>
>
> Looks OK to me ;-)
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 7: don't forget to increase your free space map settings
>