Re: Note new NULLS NOT DISTINCT on unique index tutorial page

From: Corey Huinker <corey(dot)huinker(at)gmail(dot)com>
To: David Gilman <davidgilman1(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Note new NULLS NOT DISTINCT on unique index tutorial page
Date: 2023-04-17 17:01:37
Message-ID: CADkLM=dZ8pqbx7wLKKwxTUH31_5uZ9Bc7t0bDQYc3fWY+aJBQw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Apr 12, 2023 at 10:40 AM David Gilman <davidgilman1(at)gmail(dot)com>
wrote:

> The SQL Language part of the docs has a brief page on unique indexes.
> It doesn't mention the new NULLS NOT DISTINCT functionality on unique
> indexes and this is a good place to mention it, as it already warns
> the user about the old/default behavior.
>
>
I'm ok with the wording as-is, but perhaps we can phrase it as "distinct"
vs "not equal", thus leaning into the syntax a bit:

By default, null values in a unique column are considered distinct,
allowing multiple nulls in the column.

or maybe

By default, null values in a unique column are considered
<literal>DISTINCT</literal>, allowing multiple nulls in the column.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2023-04-17 17:50:30 Re: v16dev: TRAP: failed Assert("size > SizeOfXLogRecord"), File: "xlog.c", Line: 1055, PID: 13564
Previous Message Jacob Champion 2023-04-17 16:20:37 Re: [PATCH] Add `verify-system` sslmode to use system CA pool for server cert