Re: Sort order with spaces? - Mailing list pgsql-sql

From Richard Huxton
Subject Re: Sort order with spaces?
Date
Msg-id 200309171144.02871.dev@archonet.com
Whole thread Raw
In response to Sort order with spaces?  (Kristian Jörg <krjg@devo.se>)
Responses Re: Sort order with spaces?  (Kristian Jörg <krjg@devo.se>)
List pgsql-sql
On Wednesday 17 September 2003 10:47, Kristian Jörg wrote:
> Hello!
>
> I am having troubles with sort order in Postgres. It seems that space is
> not handled at all?
> For instance the following rows are sorted in MS SQL Server as:
>
> LUNDGREN
> M L R
> MACDOWELL
> MUSCLE
>
> But in Postgres I get this order:
>
> LUNDGREN
> MACDOWELL
> M L R
> MUSCLE

Sort order depends upon your locale settings (specifically LC_COLLATE), which
will have been set when you ran "initdb". Basically, sort orders for C ,
en_GB and fr will all be different. I'm guessing you expect "C" style
sorting.

Check the end of your postgresql.conf file to see what settings you currently
have.
See the manuals (Localization section) and list archives for plenty of
details.
--  Richard Huxton Archonet Ltd


pgsql-sql by date:

Previous
From: "Martin Kuria"
Date:
Subject: Re: sub query
Next
From: Richard Huxton
Date:
Subject: Trigger order problems