Re: Can update triggers detect the column in the update statement? - Mailing list pgsql-general

From Tom Lane
Subject Re: Can update triggers detect the column in the update statement?
Date
Msg-id 1723.1223340809@sss.pgh.pa.us
Whole thread Raw
In response to Can update triggers detect the column in the update statement?  (Ben Chobot <bench@silentmedia.com>)
Responses Re: Can update triggers detect the column in the update statement?  (Ben Chobot <bench@silentmedia.com>)
List pgsql-general
Ben Chobot <bench@silentmedia.com> writes:
> Say I have:
> create t (c1 int not null, c2 int);

> Is it possible to create an update trigger on t such updates will only
> be allowed if the update statement explicitly sets c1, even if the new
> value is the same?

No.  A trigger can only tell whether the old and new values are the same
or not, not why they are that way.

            regards, tom lane

pgsql-general by date:

Previous
From: Klint Gore
Date:
Subject: Re: feature idea
Next
From: Ben Chobot
Date:
Subject: Re: Can update triggers detect the column in the update statement?