Re: minimal update trigger

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: David Fetter <david(at)fetter(dot)org>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: minimal update trigger
Date: 2008-02-20 15:16:14
Message-ID: 47BC443E.1090507@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

David Fetter wrote:
> On Tue, Feb 19, 2008 at 09:32:30PM -0500, Andrew Dunstan wrote:
>
>> As discussed a little while back, I would like to add a generic
>> trigger function which will force an update to skip if the new and
>> old tuples are identical.
>>
>
> This one has lots of use cases. Did the earlier discussion settle on
> whether there should be a GUC and/or CREATE DATABASE and/or initdb
> option for this?
>
>

None of the above. All we will be providing is a trigger function. You
would create the trigger as with any other trigger:

| CREATE TRIGGER _min BEFORE UPDATE ON mytable
FOR EACH ROW
EXECUTE PROCEDURE pg_minimal_update();

cheers

andrew
|

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Naz Gassiep 2008-02-20 16:43:43 Re: Timezone view
Previous Message Dimitri Fontaine 2008-02-20 15:06:53 Re: Permanent settings