pgsql: Implement syntax for transition tables in AFTER triggers. - Mailing list pgsql-committers

From Kevin Grittner
Subject pgsql: Implement syntax for transition tables in AFTER triggers.
Date
Msg-id E1c2grw-00022u-Gf@gemulon.postgresql.org
Whole thread Raw
List pgsql-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(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Sync our copy of the timezone library with IANA tzcode master.
Next
From: Kevin Grittner
Date:
Subject: pgsql: Improve tab completion for CREATE TRIGGER.