From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alexey Bashtanov <bashtanov@imap.cc>
Cc: pgsql-bugs@postgresql.org
Subject: Re: should all not-null constraints be inherited?
Date: Wed, 31 Mar 2021 13:02:01 -0400
Message-ID: <3228609.1617210121@sss.pgh.pa.us> (raw)
In-Reply-To: <a9514aea-af19-8b29-1713-17874fffdea0@imap.cc>
References: <a9514aea-af19-8b29-1713-17874fffdea0@imap.cc>
Alexey Bashtanov <bashtanov@imap.cc> writes:
> This is how one can create a parent with a non-nullable column and a
> child with the same column nullable:
Yeah, that's been on the to-do list for a long time. The current
theory about it is that NOT NULL constraints ought to be represented
as entries in pg_constraint like CHECKs are, so that the inheritance
count and so forth could be managed the same way. We could keep
attnotnull for convenience but it'd just mirror the existence of
the pg_constraint entry.
IIRC Alvaro had a WIP patch for this, but I've not heard anything
about it lately.
regards, tom lane
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: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, bashtanov@imap.cc
Subject: Re: should all not-null constraints be inherited?
In-Reply-To: <3228609.1617210121@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