On Thu, 6 Aug 2009 13:15:57 -0400
Merlin Moncure <mmonc...@gmail.com> wrote:

> CREATE OR REPLACE FUNCTION set_last_modified ()
> RETURNS TRIGGER
> AS $$
> BEGIN
>   IF NEW != OLD THEN  -- 8.4 syntax
>     NEW.last_modified = NOW();
>   END IF;
> 
>   RETURN NEW;
> END;
> $$ LANGUAGE PLPGSQL;

Thanks - I'll try this.  Since using 8.3 sounds like I need to
replace above with:

IF old::text != new::text 

?

I'll give it a go anyway....

Josh

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to