Re: BUG #5505: Busted referential integrity with triggers

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Tommy McDaniel" <tommstein(at)myway(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #5505: Busted referential integrity with triggers
Date: 2010-06-14 14:13:41
Message-ID: 12336.1276524821@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Tommy McDaniel" <tommstein(at)myway(dot)com> writes:
> Let us also create a trigger to disable UPDATEs on table_2:
> ...
> And, we have now broken referential integrity.

Yup, this is not a bug, it's a feature. Triggers fire on
referential-integrity updates. (If they didn't, you could not for
example have a logging trigger log RI actions.) If you don't want
to break RI, you'd better think more carefully about what your
trigger does.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2010-06-14 14:20:24 Re: BUG #5506: Error in the grammar of de joins
Previous Message Shinji Nakajima 2010-06-14 10:28:36 BUG #5507: missing chunk number 0 for toast value XXXXX in pg_toast_XXXXX