Re: BUG #18451: NULL fails to coerce to string when performing string comparison

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: Darryl Dixon <darryl(dot)dixon(at)gmail(dot)com>, "pgsql-bugs(at)lists(dot)postgresql(dot)org" <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: BUG #18451: NULL fails to coerce to string when performing string comparison
Date: 2024-04-30 22:30:46
Message-ID: 1825308.1714516246@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"David G. Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> writes:
> Fair, we don’t explicitly document that ‘…’ || NULL yields NULL. It’s more
> of “unless otherwise noted doing stuff with null results in unknown/null
> outcomes”.

Yeah, there's a documentation gap here. I dug around a little and
really couldn't find anything anywhere in our SGML docs that explains
NULL in any detail; we tend to assume that you've already heard of it.
There are a couple of parenthetical remarks in func.sgml that
reference the notion that NULL means "unknown", but you'd never
find those if you were looking for an explanation of what NULL is.
Perhaps that'd be worth a few paras somewhere, though I'm not
very sure where's a good place.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message PG Bug reporting form 2024-04-30 23:28:42 BUG #18453: --exclude-database has problems with capital letters
Previous Message Darryl Dixon 2024-04-30 22:11:58 Re: BUG #18451: NULL fails to coerce to string when performing string comparison