From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Don't clone internal triggers to partitions
Date: Tue, 03 Apr 2018 22:09:39 +0000
Message-ID: <E1f3U7X-0008BR-Nb@gemulon.postgresql.org> (raw)
Don't clone internal triggers to partitions
Trigger cloning to partitions was supposed to occur for user-visible
triggers only, but during development the protection that prevented it
from occurring to internal triggers was lost. Reinstate it, as well as
add a test case to ensure internal triggers (in the tested case,
triggers implementing a deferred unique constraint) are not cloned.
Without the code fix, the partitions in the test end up with different
numbers of triggers, which is clearly wrong ...
Bug in 86f575948c77.
Discussion: https://postgr.es/m/20180403214903.ozfagwjcpk337uw7@alvherre.pgsql
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/851f4b4e143063719553bccc73119a0d29fb1afc
Modified Files
--------------
src/backend/commands/tablecmds.c | 4 ++++
src/test/regress/expected/triggers.out | 23 +++++++++++++++++++++++
src/test/regress/sql/triggers.sql | 15 +++++++++++++++
3 files changed, 42 insertions(+)
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: alvherre@alvh.no-ip.org
Subject: Re: pgsql: Don't clone internal triggers to partitions
In-Reply-To: <E1f3U7X-0008BR-Nb@gemulon.postgresql.org>
References: <E1f3U7X-0008BR-Nb@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