From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | jbe-mlist(at)magnetkern(dot)de, PostgreSQL-development <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Parameter NOT NULL to CREATE DOMAIN not the same as CHECK (VALUE IS NOT NULL) |
Date: | 2025-01-08 23:09:47 |
Message-ID: | Z38FuyGMdLv0oLKI@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-docs pgsql-hackers |
On Wed, Jan 8, 2025 at 04:24:34PM -0500, Tom Lane wrote:
> Bruce Momjian <bruce(at)momjian(dot)us> writes:
> > I think this needs some serious research.
>
> We've discussed this topic before. The spec's definition of IS [NOT]
> NULL for composite values is bizarre to say the least. I think
> there's been an intentional choice to keep most NOT NULL checks
> "simple", that is we look at the overall value's isnull bit and
> don't probe any deeper than that.
>
> If the optimizations added in v17 changed existing behavior,
> I agree that's bad. We should probably fix it so that those
> are only applied when argisrow is false.
Okay, makes sense. Do we have any sense of whether the docs can be
improved in this area, based on the original email report? Here is a
proposed patch for that.
--
Bruce Momjian <bruce(at)momjian(dot)us> https://momjian.us
EDB https://enterprisedb.com
Do not let urgent matters crowd out time for investment in the future.
Attachment | Content-Type | Size |
---|---|---|
domain.diff | text/x-diff | 770 bytes |
From | Date | Subject | |
---|---|---|---|
Next Message | Jeff Davis | 2025-01-08 23:19:58 | Re: Add CASEFOLD() function. |
Previous Message | Tom Lane | 2025-01-08 23:07:44 | Re: use a non-locking initial test in TAS_SPIN on AArch64 |
From | Date | Subject | |
---|---|---|---|
Previous Message | Tom Lane | 2025-01-08 21:24:34 | Re: Parameter NOT NULL to CREATE DOMAIN not the same as CHECK (VALUE IS NOT NULL) |