Re: Order of triggers and sequences...

From: Terry Lee Tucker <terry(at)esc1(dot)com>
To: Alex Mayrhofer <axelm(at)nona(dot)net>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Order of triggers and sequences...
Date: 2006-04-29 12:42:55
Message-ID: 200604290842.55618.terry@esc1.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Saturday 29 April 2006 08:34 am, Alex Mayrhofer <axelm(at)nona(dot)net> thus
communicated:
--> Hi,
-->
--> i'm about to implement a trigger on a table with an id field populated by
a --> sequence (the usual 'id SERIAL NOT NULL PRIMARY KEY').
-->
--> Just a short (probably lame) question: Would a "BEFORE INSERT" row level
--> trigger already see a populated 'id' column, or would that happen after
all --> triggers on the actual insert?
-->
--> thanks,
-->
--> Alex
-->

In my experience, all the triggers see all the data all the time in varying
combinations of the OLD and NEW buffers.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Florian G. Pflug 2006-04-29 13:30:40 Re: Alternative for vacuuming queue-like tables
Previous Message Alex Mayrhofer 2006-04-29 12:34:16 Order of triggers and sequences...