From: Tom Lane <tgl@sss.pgh.pa.us>
To: Martin <hier-bei-mir@gmx.net>
Cc: pgsql-bugs@postgresql.org
Subject: Re: Re: AfterTriggerSaveEvent() Error on altered foreign key cascaded delete
Date: Wed, 26 Apr 2017 12:30:02 -0400
Message-ID: <6536.1493224202@sss.pgh.pa.us> (raw)
In-Reply-To: <1493223536261-5958509.post@n3.nabble.com>
References: <CAJ3Xv+jzJ8iNNUcp4RKW8b6Qp1xVAxHwSXVpjBNygjKxcVuE9w@mail.gmail.com>
<24945.1477510973@sss.pgh.pa.us>
<1493223536261-5958509.post@n3.nabble.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
Martin <hier-bei-mir@gmx.net> writes:
> I am facing the exact same bug when using circular references:
I see no error when I try this example in HEAD. I think possibly you
are hitting a bug we fixed last year:
Author: Tom Lane <tgl@sss.pgh.pa.us>
Branch: master [a522fc3d8] 2016-10-26 17:05:06 -0400
Branch: REL9_6_STABLE Release: REL9_6_2 [445035a6e] 2016-10-26 17:05:06 -0400
Branch: REL9_5_STABLE Release: REL9_5_6 [b53c841e5] 2016-10-26 17:05:06 -0400
Branch: REL9_4_STABLE Release: REL9_4_11 [3a9a8c408] 2016-10-26 17:05:06 -0400
Fix incorrect trigger-property updating in ALTER CONSTRAINT.
The code to change the deferrability properties of a foreign-key constraint
updated all the associated triggers to match; but a moment's examination of
the code that creates those triggers in the first place shows that only
some of them should track the constraint's deferrability properties. This
leads to odd failures in subsequent exercise of the foreign key, as the
triggers are fired at the wrong times. Fix that, and add a regression test
comparing the trigger properties produced by ALTER CONSTRAINT with those
you get by creating the constraint as-intended to begin with.
Per report from James Parks. Back-patch to 9.4 where this ALTER
functionality was introduced.
Report: <CAJ3Xv+jzJ8iNNUcp4RKW8b6Qp1xVAxHwSXVpjBNygjKxcVuE9w@mail.gmail.com>
If you're not running a current minor release, please update.
regards, tom lane
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, hier-bei-mir@gmx.net
Subject: Re: AfterTriggerSaveEvent() Error on altered foreign key cascaded delete
In-Reply-To: <6536.1493224202@sss.pgh.pa.us>
References: <CAJ3Xv+jzJ8iNNUcp4RKW8b6Qp1xVAxHwSXVpjBNygjKxcVuE9w@mail.gmail.com> <24945.1477510973@sss.pgh.pa.us> <1493223536261-5958509.post@n3.nabble.com> <6536.1493224202@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox