pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter_e@gmx.net>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Apply RI trigger skipping tests also for DELETE
Date: Sat, 10 Nov 2018 15:21:21 +0000
Message-ID: <E1gLV4b-00089E-Kz@gemulon.postgresql.org> (raw)

Apply RI trigger skipping tests also for DELETE

The tests added in cfa0f4255bb0f5550d37a01c4d8fe2966d20040c to skip
firing an RI trigger if any old key value is NULL can also be applied
for DELETE.  This should give a performance gain in those cases, and it
also saves a lot of duplicate code in the actual RI triggers.  (That
code was already dead code for the UPDATE cases.)

Reviewed-by: Daniel Gustafsson <daniel@yesql.se>

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/69ee2ff9308bbfe0e0a89667555e901fec5e154b

Modified Files
--------------
src/backend/commands/trigger.c      |   4 +-
src/backend/utils/adt/ri_triggers.c | 105 ++----------------------------------
2 files changed, 6 insertions(+), 103 deletions(-)



Message-ID: <E1gLV4b-00089E-Kz@gemulon.postgresql.org>
Permalink:  ../E1gLV4b-00089E-Kz@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1gLV4b-00089E-Kz@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: peter_e@gmx.net
  Subject: Re: pgsql: Apply RI trigger skipping tests also for DELETE
  In-Reply-To: <E1gLV4b-00089E-Kz@gemulon.postgresql.org>
  References: <E1gLV4b-00089E-Kz@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