From: | "Oliveiros C," <oliveiros(dot)cristina(at)marktest(dot)pt> |
---|---|
To: | "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | "Adrian Klaver" <aklaver(at)comcast(dot)net>, <pgsql-sql(at)postgresql(dot)org> |
Subject: | Re: How to order varchar data by word |
Date: | 2009-10-20 13:39:23 |
Message-ID: | 754C7C57E773410197FA4BF910DE9973@marktestcr.marktest.pt |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
Hello, Tom.
Thank you for your e-mail
Even though I am not familiar with the exact procedure to switch to other
locales,
I'm gonna research this more deeply.
Anyway, I would appreciate if you could spare me some time and give me a
couple of pointers to this subject.
Again, thank you
Best,
Oliveiros
----- Original Message -----
From: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Oliveiros C," <oliveiros(dot)cristina(at)marktest(dot)pt>
Cc: "Adrian Klaver" <aklaver(at)comcast(dot)net>; <pgsql-sql(at)postgresql(dot)org>
Sent: Monday, October 19, 2009 6:32 PM
Subject: Re: [SQL] How to order varchar data by word
> "Oliveiros C," <oliveiros(dot)cristina(at)marktest(dot)pt> writes:
>> If any one can explain me exactly how the order by clause works on
>> varchars,
>> I 'd really appreciate it.
>
> It sorts according to the sort order imposed by your locale setting
> (see LC_COLLATE in particular).
>
> A lot of locales have weird and wonderful rules that embody somebody's
> notion of "dictionary order". If you don't like it, try switching to
> C locale. Or you could learn enough about locale definitions to create
> your own.
>
> regards, tom lane
>
> --
> Sent via pgsql-sql mailing list (pgsql-sql(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-sql
From | Date | Subject | |
---|---|---|---|
Next Message | Adrian Klaver | 2009-10-20 13:46:45 | Re: How to order varchar data by word |
Previous Message | Tom Lane | 2009-10-19 22:55:38 | Re: Dynamic Query |