From: Tom Lane <tgl@sss.pgh.pa.us>
To: 1726002692@qq.com
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #15919: When sorting, does the result show that S > s is correct?
Date: Fri, 19 Jul 2019 10:16:13 -0400
Message-ID: <23071.1563545773@sss.pgh.pa.us> (raw)
In-Reply-To: <15919-187cdb0f64d34ab9@postgresql.org>
References: <15919-187cdb0f64d34ab9@postgresql.org>
PG Bug reporting form <noreply@postgresql.org> writes:
> postgres@[local]:5433[postgres]#select * from t order by info asc;
> +------+
> | info |
> +------+
> | s |
> | S |
> +------+
> (2 rows)
This is the expected behavior for en_US locale, as you can easily
confirm outside of Postgres:
$ (echo s; echo S) | LANG=en_US sort
s
S
Perhaps you are confusing it with C locale?
$ (echo s; echo S) | LANG=C sort
S
s
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, 1726002692@qq.com
Subject: Re: BUG #15919: When sorting, does the result show that S > s is correct?
In-Reply-To: <23071.1563545773@sss.pgh.pa.us>
References: <15919-187cdb0f64d34ab9@postgresql.org> <23071.1563545773@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox