pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kaleb Akalework <kaleb.akalework@asg.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-bugs@lists.postgresql.org <pgsql-bugs@lists.postgresql.org>
Subject: RE: BUG #15651: Collation setting en_US.utf8 breaking sort order
Date: Fri, 22 Feb 2019 18:18:16 +0000
Message-ID: <4ce38aace626460e85ed2abe0051371c@asg.com> (raw)
In-Reply-To: <17689.1550858606@sss.pgh.pa.us>
References: <15651-0caa86edc3ca0505@postgresql.org>
	<17689.1550858606@sss.pgh.pa.us>

--> Really?  AFAIK, Windows doesn't support collation names that look like that.
I meant to say Linux. Not Windows.


-----Original Message-----
From: Tom Lane <tgl@sss.pgh.pa.us> 
Sent: Friday, February 22, 2019 1:03 PM
To: Kaleb Akalework <kaleb.akalework@asg.com>
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #15651: Collation setting en_US.utf8 breaking sort order

*** External email: Verify sender before opening attachments or links ***


PG Bug reporting form <noreply@postgresql.org> writes:
> I have PostgresSQL database on Windows. I created database with 
> Collation of en_US.utf8.

Really?  AFAIK, Windows doesn't support collation names that look like that.

> Then I created table (The steps to reproduce are below). I inserted a 
> few rows into this table one of which was row with special characters 
> "~!@#$^&(". The insert worked fine but then when I do a select on the 
> column for values >=' ' (Space), I get back all the rows except for 
> the row that contains "~!@#$^&(" .

This appears to be the intended behavior of en_US sorting.
On a Linux machine I can reproduce it outside Postgres:

$ LANG=C sort stuff.txt

AAA
BAA
CAA
DAA
~!@#$^&(
$ LANG=en_US sort stuff.txt
~!@#$^&(

AAA
BAA
CAA
DAA

(The first line in my test file contains one space.)

                        regards, tom lane




view thread (9+ messages)  latest in thread

Message-ID: <4ce38aace626460e85ed2abe0051371c@asg.com>
Permalink:  ../4ce38aace626460e85ed2abe0051371c@asg.com/
Also on:    postgresql.org/message-id/4ce38aace626460e85ed2abe0051371c@asg.com

 · 

reply

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: kaleb.akalework@asg.com, tgl@sss.pgh.pa.us
  Subject: Re: BUG #15651: Collation setting en_US.utf8 breaking sort order
  In-Reply-To: <4ce38aace626460e85ed2abe0051371c@asg.com>
  References: <15651-0caa86edc3ca0505@postgresql.org> <17689.1550858606@sss.pgh.pa.us> <4ce38aace626460e85ed2abe0051371c@asg.com>

* 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