Re: Triggers and System Tables

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Hans-Juergen Schoenig <hs(at)cybertec(dot)at>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Triggers and System Tables
Date: 2002-04-16 13:59:18
Message-ID: 11916.1018965558@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hans-Juergen Schoenig <hs(at)cybertec(dot)at> writes:
> I have a brief question concerning triggers and system tables:
> Why is it not allowed to trigger a system table?

Most of the operations that modify system tables don't bother to fire
triggers ... so if you had a trigger, it would generally fail to capture
the interesting events. I'm not sure what the feasibility would be of
firing triggers everywhere that system tables are updated. Offhand I'd
be worried about whether the system is in a sufficiently self-consistent
state to support trigger execution at all those points.

It would probably also be a *really bad* idea to install a trigger that
tries to alter the row or suppress the update ;-)

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Maurice Balick 2002-04-16 14:02:42 Re: index problem (uses one index but not the other)
Previous Message Maurice Balick 2002-04-16 13:53:20 Re: index problem (uses one index but not the other)