pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: pgsql-committers@postgresql.org
Subject: Re: pgsql: Add function to import operating system collations
Date: Wed, 18 Jan 2017 12:37:01 -0500
Message-ID: <19773.1484761021@sss.pgh.pa.us> (raw)
In-Reply-To: <9b99c8c5-5a77-f1ae-6d90-bef0e85552a0@2ndquadrant.com>
References: <E1cTrLM-0008E8-6K@gemulon.postgresql.org>
	<26116.1484751196@sss.pgh.pa.us>
	<2083.1484754187@sss.pgh.pa.us>
	<9b99c8c5-5a77-f1ae-6d90-bef0e85552a0@2ndquadrant.com>
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

Peter Eisentraut <peter.eisentraut@2ndquadrant.com> writes:
> What's fishy about this is that I can't reproduce it locally in a
> variety of VMs, and the buildfarm is not unanimous either.

Well, as I said, I get

$ locale -a | grep ^aa_ER
aa_ER
aa_ER.utf8
aa_ER.utf8@saaho
aa_ER@saaho

What it looks like to me is that we see "aa_ER.utf8@saaho", enter
that, strip it to "aa_ER@saaho" and enter that (if_not_exists,
which it doesn't), and then see "aa_ER@saaho" which we try to
enter and fail.  IOW, the behavior is dependent on the order in
which "locale -a" returns the names, which I already mentioned
I do not think we should trust to be consistent.

The previous coding applied a sort so as not to depend on what
order "locale -a" had returned things in, and I think we need
to retain that.  At the very least, all the normalized names
need to be saved up and entered in a second pass.

			regards, tom lane


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers



view thread (24+ messages)  latest in thread

Message-ID: <19773.1484761021@sss.pgh.pa.us>
Permalink:  ../19773.1484761021@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/19773.1484761021@sss.pgh.pa.us

 · 

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-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, peter.eisentraut@2ndquadrant.com
  Subject: Re: pgsql: Add function to import operating system collations
  In-Reply-To: <19773.1484761021@sss.pgh.pa.us>
  References: <E1cTrLM-0008E8-6K@gemulon.postgresql.org> <26116.1484751196@sss.pgh.pa.us> <2083.1484754187@sss.pgh.pa.us> <9b99c8c5-5a77-f1ae-6d90-bef0e85552a0@2ndquadrant.com> <19773.1484761021@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