Re: System Tables and Triggers

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Stef Telford <stef(at)chronozon(dot)artofdns(dot)com>
Cc: PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: System Tables and Triggers
Date: 2003-03-02 17:43:36
Message-ID: 18602.1046627016@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Stef Telford <stef(at)chronozon(dot)artofdns(dot)com> writes:
> This would seem to be a step backwards to me though, as
> now we cant even put triggers on the system tables. Is there any
> chance of this being lifted ?

Not unless you can explain to us how it can be safe to fire arbitrary
user-defined code when the system tables are in inconsistent
intermediate states. Few commands change only one row of only one
catalog.

It may be (I haven't thought about it too hard) that it would be safe to
allow AFTER triggers on some tables. But implementing it --- that is,
actually getting the triggers to be executed --- would be a lot of work.
And I'm afraid of the potential for nasty problems if such a trigger
raises an error or recursively invokes other catalog updates.

Bottom line is that this would be a large, difficult project with
(IMHO) relatively low return. It may get done someday, but don't
hold your breath.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2003-03-02 18:21:11 Re: GiST: Bad newtup On Exit From gistSplit() ?
Previous Message Itai Zukerman 2003-03-02 17:39:31 Re: GiST: Bad newtup On Exit From gistSplit() ?