Re: logging table changes - Mailing list pgsql-novice

From Richard Broersma
Subject Re: logging table changes
Date
Msg-id AANLkTi=ofXWpgf4KOO4c_MkzYRLShE60WyS=d6+EUBJH@mail.gmail.com
Whole thread Raw
In response to Re: logging table changes  ("Rob Richardson" <Rob.Richardson@rad-con.com>)
List pgsql-novice
On Thu, Sep 9, 2010 at 10:48 AM, Rob Richardson
<Rob.Richardson@rad-con.com> wrote:

>
> If old.value <> new.value then
>        do something
> End if

If old.value IS DISTINCT FROM new.value THEN
  --do something
End if


This version will produce expected results when dealing with nulls.  I
learned this the hard way.

--
Regards,
Richard Broersma Jr.

Visit the Los Angeles PostgreSQL Users Group (LAPUG)
http://pugs.postgresql.org/lapug

pgsql-novice by date:

Previous
From: "Rob Richardson"
Date:
Subject: Re: logging table changes
Next
From: Matthias Leopold
Date:
Subject: Re: logging table changes