Re: Triggers using PL/pgSQL - Mailing list pgsql-sql

From Milen A. Radev
Subject Re: Triggers using PL/pgSQL
Date
Msg-id 44CE2BEE.2070201@radev.net
Whole thread Raw
In response to Triggers using PL/pgSQL  (Thusitha Kodikara <kthusi@yahoo.com>)
List pgsql-sql
Thusitha Kodikara написа:
> Hello,
> 
> I am interested in developing some triggers to keep track of records that are changed (possibly the changes of one or
morespecific columns). In addition to keeping the new values, I also need to keep the old values (may be on a separate
table). 
 
> 
> Though I  have done similar things in other RDBMs using SQL, I find doing this in Postgres, a little bit complicated
-may be because it needs to be done through a separate procedural language and through a separate function. The
Postgresdocumentation also didn't provide much help ( the examples in C). I was mainly looking for example showing how
torefer 'OLD' and 'NEW' rows using PL/pgSQL.
 
> 
> Can someone please direct me to some such examples?


http://www.postgresql.org/docs/8.1/static/plpgsql-trigger.html


-- 
Milen A. Radev



pgsql-sql by date:

Previous
From: Ken Hill
Date:
Subject: Re: Triggers using PL/pgSQL
Next
From: George Weaver
Date:
Subject: Re: Triggers using PL/pgSQL