Bruce Momjian <bruce@momjian.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.
regards, tom lane