Re: [INTERFACES] [pgaccess-users] RE: bugzilla.pgaccess.org

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bradley Baetz <bbaetz(at)student(dot)usyd(dot)edu(dot)au>
Cc: Rod Taylor <rbt(at)zort(dot)ca>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
Subject: Re: [INTERFACES] [pgaccess-users] RE: bugzilla.pgaccess.org
Date: 2002-07-11 03:25:05
Message-ID: 13263.1026357905@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bradley Baetz <bbaetz(at)student(dot)usyd(dot)edu(dot)au> writes:
> I'm referring to the mysql |timestamp| type, which will update that
> column's contents to |now()| when any UPDATE is given for that partcular
> row, unless the column was assigned to. I don't know how to handle the
> last part in a trigger.

It'd probably be close enough to have an UPDATE trigger that does

if (new.timestamp = old.timestamp)
new.timestamp = now();

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bradley Baetz 2002-07-11 03:29:26 Re: [INTERFACES] [pgaccess-users] RE: bugzilla.pgaccess.org
Previous Message Bruce Momjian 2002-07-11 03:24:34 Re: Should this require CASCADE?