Support SQL-compliant triggers on columns, ie fire only if certain columns
Tom Lane <tgl@sss.pgh.pa.us>
Support SQL-compliant triggers on columns, ie fire only if certain columns are named in the UPDATE's SET list. Note: the schema of pg_trigger has not actually changed; we've just started to use a column that was there all along. catversion bumped anyway so that this commit is included in the history of potentially interesting changes to system catalog contents. Itagaki Takahiro
Files
| Path | Change | +/− |
|---|---|---|
| doc/src/sgml/catalogs.sgml | modified | +12 −3 |
| doc/src/sgml/ref/create_trigger.sgml | modified | +30 −14 |
| doc/src/sgml/trigger.sgml | modified | +8 −5 |
| src/backend/catalog/index.c | modified | +2 −1 |
| src/backend/commands/tablecmds.c | modified | +4 −1 |
| src/backend/commands/trigger.c | modified | +151 −110 |
| src/backend/nodes/copyfuncs.c | modified | +2 −1 |
| src/backend/nodes/equalfuncs.c | modified | +2 −1 |
| src/backend/optimizer/plan/setrefs.c | modified | +3 −2 |
| src/backend/parser/gram.y | modified | +31 −10 |
| src/backend/utils/adt/ruleutils.c | modified | +18 −1 |
| src/bin/pg_dump/pg_dump.c | modified | +13 −1 |
| src/include/catalog/catversion.h | modified | +2 −2 |
| src/include/catalog/pg_trigger.h | modified | +3 −3 |
| src/include/nodes/parsenodes.h | modified | +4 −4 |
| src/test/regress/expected/triggers.out | modified | +102 −17 |
| src/test/regress/sql/triggers.sql | modified | +46 −7 |