Re: Order of triggers - totally lost

From: SZŰCS Gábor <surrano(at)mailbox(dot)hu>
To: <pgsql-sql(at)postgresql(dot)org>
Subject: Re: Order of triggers - totally lost
Date: 2003-08-13 15:40:26
Message-ID: 003e01c361b1$37d02780$0403a8c0@fejleszt4
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Dear Jonathan,

Thanks for your will to help.

It would be a bit difficult to clean up everything as much as possible
(while keeping the problem) and send the skeleton.

It looks like the A_AU trigger I mentioned solved the problem.

Actually, the situation I painted is much much simplified compared to the
real one (about 20 or more tables are accessed during that "simple 1-line
update"). What I'd probably use best, are some generic guidelines:

* what is sure about trigger execution order?
(Cristoph Haller partially answered my question, quoting future plans)
* are there generic recommendations what kind of things to put in
before and after triggers?
* how about FOR EACH STATEMENT triggers?
(we only use FOR EACH ROW triggers)

G.
------------------------------- cut here -------------------------------
----- Original Message -----
From: "Jonathan Gardner" <jgardner(at)jonathangardner(dot)net>
Sent: Wednesday, August 13, 2003 4:54 PM

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wednesday 13 August 2003 03:11, SZŰCS Gábor wrote:
>
> What may be wrong? Any ideas to re-organize parts of the triggers?
> May putting the update to an A_AU trigger help? I tried it, still
> have problems (not sure it's still the trigger order), but the
> trigger order is still strange for me:

I'd need some solid code to solve this. Can you send the create
statements and the insert statement that started it all? I get the
feeling that you may have more triggers than you really need.

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Josh Berkus 2003-08-13 15:55:04 Re: Order of triggers - totally lost
Previous Message Jonathan Gardner 2003-08-13 14:54:30 Re: Order of triggers - totally lost