Re: 8.3 PL/pgSQL comparing arbitrary records

From: Josh Kupershmidt <schmiddy(at)gmail(dot)com>
To: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
Cc: Postgres General <pgsql-general(at)postgresql(dot)org>
Subject: Re: 8.3 PL/pgSQL comparing arbitrary records
Date: 2009-12-15 14:04:06
Message-ID: 4ec1cf760912150604w6a834ac6j8189887dfdbedb44@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Dec 15, 2009 at 1:23 AM, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> wrote:
> Hello
>
> NEW and OLD is comparable in 8.4. In 8.3 and older you have to use
> little bit different syntax
>
> http://www.postgres.cz/index.php/PostgreSQL_SQL_Tricks#Fast_compare_variables_NEW_and_OLD_in_trigger.27s_body
>

Thanks, Pavel! This is exactly what I was looking for. I am able to use

IF ROW(NEW.*) IS NOT DISTINCT FROM ROW(OLD.*) THEN ...

on 8.3.

Josh

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Scott Mead 2009-12-15 14:10:15 Re: Too many postgres.exe
Previous Message Howard Cole 2009-12-15 13:26:54 Re: How to remove non-UTF values from a table?