Re: Support NOT VALID / VALIDATE constraint options for named NOT NULL constraints
Robert Haas <robertmhaas@gmail.com>
From: Robert Haas <robertmhaas@gmail.com>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Rushabh Lathia <rushabh.lathia@gmail.com>,
Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>, PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Date: 2025-03-24T17:47:50Z
Lists: pgsql-hackers
On Mon, Mar 24, 2025 at 12:29 PM Alvaro Herrera <alvherre@alvh.no-ip.org> wrote: > > Again, I'm not 100% positive that changing the Boolean column to a > > three-valued column is the right way forward, but it does have the > > advantage of saving a byte, and the width of system catalog tables has > > been a periodic concern. > > In this case, as I already said, the new boolean column would go in > what's currently padding space, so there's no widening taking place. IMHO, there will almost certainly be more single-byte columns at some point in the future, so I feel like using up padding space is not much different than actual widening over the long term. > Please don't think that I'm in favor of doing it the difficult way for > no reason. Previous versions of the patch (changing attnotnull to > char), from the Postgres core code perspective, were pretty much ready > -- we're having this discussion only to avoid the breakage. I could > save us a bunch of time here and just push those patches, but I think > the responsible thing here (the one we're less likely to regret) is not > to. Fair enough. I think I've said what I want to say, and I'm not here to substitute my judgement for yours. -- Robert Haas EDB: http://www.enterprisedb.com
Commits
-
Allow NOT NULL constraints to be added as NOT VALID
- a379061a22a8 18.0 landed
-
Add missing deparsing of [NO] IDENT to XMLSERIALIZE()
- 984410b92326 18.0 cited
-
backend launchers void * arguments for binary data
- 7202d72787d3 18.0 cited
-
Add pg_constraint rows for not-null constraints
- 14e87ffa5c54 18.0 cited
-
Create the infrastructure for planner support functions.
- 1fb57af92069 12.0 cited
-
Add prokind column, replacing proisagg and proiswindow
- fd1a421fe661 11.0 cited