Re: Transition tables for triggers on foreign tables and views
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Kevin Grittner <kgrittn@gmail.com>
Cc: Thomas Munro <thomas.munro@enterprisedb.com>,
Pg Hackers <pgsql-hackers@postgresql.org>
Date: 2017-04-29T03:56:18Z
Lists: pgsql-hackers
Kevin Grittner <kgrittn@gmail.com> writes: > Well, I was sort of hoping that the triggers that can now be defined > but can never fire *did* fire at some point. They will fire if you have an INSTEAD OF row-level trigger; the existence of that trigger is what determines whether we implement DML on a view through the view's own triggers or through translation to an action on the underlying table. I do not think it'd be reasonable to throw an error for creation of a statement-level view trigger when there's no row-level trigger, because that just imposes a hard-to-deal-with DDL ordering dependency. You could make a case for having the updatable-view translation code print a WARNING if it notices that there are statement-level triggers that cannot be fired due to the translation. regards, tom lane
Commits
-
Prohibit transition tables on views and foreign tables.
- 9e6104c6672d 10.0 landed