From: Kevin Grittner <kgrittn@postgresql.org>
To: pgsql-committers@postgresql.org
Subject: pgsql: Implement syntax for transition tables in AFTER triggers.
Date: Fri, 04 Nov 2016 15:57:28 +0000
Message-ID: <E1c2grw-00022u-Gf@gemulon.postgresql.org> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>
Implement syntax for transition tables in AFTER triggers.
This is infrastructure for the complete SQL standard feature. No
support is included at this point for execution nodes or PLs. The
intent is to add that soon.
As this patch leaves things, standard syntax can create tuplestores
to contain old and/or new versions of rows affected by a statement.
References to these tuplestores are in the TriggerData structure.
C triggers can access the tuplestores directly, so they are usable,
but they cannot yet be referenced within a SQL statement.
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/8c48375e5f43ebd832f93c9166d1fe0e639ff806
Modified Files
--------------
doc/src/sgml/catalogs.sgml | 16 ++
doc/src/sgml/ref/create_trigger.sgml | 94 ++++++++--
src/backend/commands/tablecmds.c | 5 +-
src/backend/commands/trigger.c | 327 +++++++++++++++++++++++++++++++++--
src/backend/nodes/copyfuncs.c | 16 ++
src/backend/nodes/equalfuncs.c | 14 ++
src/backend/nodes/outfuncs.c | 13 ++
src/backend/parser/gram.y | 70 +++++++-
src/backend/utils/adt/ruleutils.c | 23 +++
src/include/catalog/catversion.h | 2 +-
src/include/catalog/pg_trigger.h | 13 +-
src/include/commands/trigger.h | 2 +
src/include/nodes/nodes.h | 1 +
src/include/nodes/parsenodes.h | 17 ++
src/include/parser/kwlist.h | 3 +
src/include/utils/reltrigger.h | 7 +
16 files changed, 580 insertions(+), 43 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
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: kgrittn@postgresql.org
Subject: Re: pgsql: Implement syntax for transition tables in AFTER triggers.
In-Reply-To: <E1c2grw-00022u-Gf@gemulon.postgresql.org>
References: <E1c2grw-00022u-Gf@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