From: | "Teemu Juntunen" <teemu(dot)juntunen(at)e-ngine(dot)fi> |
---|---|
To: | "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | "PostgreSQL" <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: After delete trigger problem |
Date: | 2008-11-08 04:54:46 |
Message-ID: | 1A06982497A3422A93321D7FC2C70F99@eng02 |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hi,
thanks for answers!
I tried to rename the function
ALTER TRIGGER td_y ON child RENAME TO "BTD_Y";
with no help.
Also according to the manual BEFORE DELETE trigger should launch before
casading delete, so I changed the trigger
CREATE TRIGGER "BTD_Y" BEFORE DELETE ON chlid FOR EACH ROW EXECUTE
PROCEDURE fn_td_y();
with no help. Any other ideas?
Regards,
Teemu Juntunen
----- Original Message -----
From: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Teemu Juntunen" <teemu(dot)juntunen(at)e-ngine(dot)fi>
Cc: "PostgreSQL" <pgsql-general(at)postgresql(dot)org>
Sent: Friday, November 07, 2008 9:23 PM
Subject: Re: [GENERAL] After delete trigger problem
> "Teemu Juntunen" <teemu(dot)juntunen(at)e-ngine(dot)fi> writes:
>> CREATE TRIGGER td_y AFTER DELETE ON chlid FOR EACH ROW EXECUTE
>> PROCEDURE fn_td_y();
>
>> It seems that SELECT results to null, so the master has already deleted
>> the row. Is this intended and how can I solve this?
>
> Your trigger is firing after the RI triggers. If you want it to fire
> before, give it a name that is before them (in ASCII order).
>
> regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Owen Hartnett | 2008-11-08 05:01:07 | Re: postgresql and Mac OS X |
Previous Message | Tom Lane | 2008-11-08 04:54:16 | Re: Short CVS question, history |