public inbox for [email protected]
help / color / mirror / Atom feedFrom: Álvaro Herrera <[email protected]>
To: Amul Sul <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: Allow NOT VALID foreign key constraints on partitioned tables.
Date: Tue, 21 Jan 2025 22:06:14 +0100
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAAJ_b95pjru9JxU4Ve8yRFSCPO8VNmur8jfuHrACWuTBDt97zg@mail.gmail.com>
Suppose I have a hierarchy like this
parent
|
child
/\
/ \
/ grandchild2
/
grandchild1
and I have a validated constraint on grandchild1 and an invalid
constraint on child. What happens if I add a constraint on parent? In
my understanding, it should not attempt to revalidate the constraint on
grandchild1, because it's known valid; but I don't think I see code that
would skip validation there. That is, QueueFKConstraintValidation does
its thing unconditionally (esp. recursing to children), which seems
wrong.
--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/
"I am amazed at [the pgsql-sql] mailing list for the wonderful support, and
lack of hesitasion in answering a lost soul's question, I just wished the rest
of the mailing list could be like this." (Fotis)
https://postgr.es/m/[email protected]
view thread (6+ messages) latest in thread
reply
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 using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: Allow NOT VALID foreign key constraints on partitioned tables.
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox