Re: Possible bug in Postgres String comparison routines

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Breton <pbreton(at)MIT(dot)EDU>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: Possible bug in Postgres String comparison routines
Date: 2001-10-25 14:04:05
Message-ID: 13740.1004018645@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Peter Breton <pbreton(at)MIT(dot)EDU> writes:
> Is there something that I'm not understanding here, or is this a bug?

What locale are you using? Non-C locales have sorting rules more
complex than you seem to be expecting.

$ cat data
e
,
ke
k,
ken
k,
kens
k, P
ens
, P
$ LANG=C sort data
,
, P
e
ens
k,
k,
k, P
ke
ken
kens
$ LANG=en_US.iso88591 sort data
e
ens
ke
ken
kens
k,
k,
k, P
,
, P
$

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2001-10-25 14:12:14 Re: Enabling --debug causes regression test failure.
Previous Message Tom Lane 2001-10-25 03:43:11 Re: Bug #491: ERROR: RelationClearRelation: relation using JDBC