Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s1vzz-00G8RV-Fg for pgsql-bugs@arkaria.postgresql.org; Tue, 30 Apr 2024 22:30:55 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1s1vzv-0095Yj-1Z for pgsql-bugs@arkaria.postgresql.org; Tue, 30 Apr 2024 22:30:51 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s1vzu-0095Ya-P5 for pgsql-bugs@lists.postgresql.org; Tue, 30 Apr 2024 22:30:51 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s1vzr-000q5l-Nd for pgsql-bugs@lists.postgresql.org; Tue, 30 Apr 2024 22:30:50 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 43UMUkCL1825309; Tue, 30 Apr 2024 18:30:46 -0400 From: Tom Lane To: "David G. Johnston" cc: Darryl Dixon , "pgsql-bugs@lists.postgresql.org" Subject: Re: BUG #18451: NULL fails to coerce to string when performing string comparison In-reply-to: References: <18451-dc130ad59b7bd7c9@postgresql.org> Comments: In-reply-to "David G. Johnston" message dated "Tue, 30 Apr 2024 15:09:06 -0700" MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <1825307.1714516246.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Tue, 30 Apr 2024 18:30:46 -0400 Message-ID: <1825308.1714516246@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk "David G. Johnston" writes: > Fair, we don=E2=80=99t explicitly document that =E2=80=98=E2=80=A6=E2=80= =99 || NULL yields NULL. It=E2=80=99s more > of =E2=80=9Cunless otherwise noted doing stuff with null results in unkn= own/null > outcomes=E2=80=9D. 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