pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Stabilize pg_dump output order for similarly-named triggers and
Date: Mon, 04 Nov 2019 21:25:30 +0000
Message-ID: <E1iRjqs-0003vJ-3j@gemulon.postgresql.org> (raw)

Stabilize pg_dump output order for similarly-named triggers and policies.

The code only compared two triggers' names and namespaces (the latter
being the owning table's schema).  This could result in falling back
to an OID-based sort of similarly-named triggers on different tables.
We prefer to avoid that, so add a comparison of the table names too.
(The sort order is thus table namespace, trigger name, table name,
which is a bit odd, but it doesn't seem worth contorting the code
to work around that.)

Likewise for policy objects, in 9.5 and up.

Complaint and fix by Benjie Gillam.  Back-patch to all supported
branches.

Discussion: https://postgr.es/m/CAMThMzEEt2mvBbPgCaZ1Ap1N-moGn=Edxmadddjq89WG4NpPtQ@mail.gmail.com

Branch
------
REL9_5_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/74d32ee704ebe01d9336d6116449603a3fe6462d

Modified Files
--------------
src/bin/pg_dump/pg_dump_sort.c | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)



view thread (7+ messages)  latest in thread

Message-ID: <E1iRjqs-0003vJ-3j@gemulon.postgresql.org>
Permalink:  ../E1iRjqs-0003vJ-3j@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1iRjqs-0003vJ-3j@gemulon.postgresql.org

 · 

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
  Subject: Re: pgsql: Stabilize pg_dump output order for similarly-named triggers and
  In-Reply-To: <E1iRjqs-0003vJ-3j@gemulon.postgresql.org>
  References: <E1iRjqs-0003vJ-3j@gemulon.postgresql.org>

* 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