Re: Missing "CONSTRAINT" keyword in ADD CONSTRAINT form?

From: Tim Needham <tim(dot)needham2(at)gmail(dot)com>
To: tim(dot)needham2(at)gmail(dot)com, pgsql-docs(at)lists(dot)postgresql(dot)org
Subject: Re: Missing "CONSTRAINT" keyword in ADD CONSTRAINT form?
Date: 2023-12-04 20:38:20
Message-ID: CAAGa=sK9nT5XuhT=TdqmP8NM57dWECh708ierHzCAEGBp1ShFQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

Bah, scratch that, sorry again. It's because "CONSTRAINT" is implied by the
reference to CREATE DOMAIN, isn't it?
Sorry.

On Mon, Dec 4, 2023 at 8:29 PM PG Doc comments form <noreply(at)postgresql(dot)org>
wrote:

> The following documentation comment has been logged on the website:
>
> Page: https://www.postgresql.org/docs/16/sql-alterdomain.html
> Description:
>
> (apologies, I managed to send this too soon, just now, somehow)
>
> The example for ALTER DOMAIN shows:
>
> ALTER DOMAIN zipcode ADD CONSTRAINT zipchk CHECK (char_length(VALUE) = 5);
>
> ...yet the syntax suggests no CONSTRAINT-keyword (I'm guessing?) should be
> used:
>
> ALTER DOMAIN name ADD domain_constraint [ NOT VALID ]
>
> When it should, I think?
>

In response to

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message David G. Johnston 2023-12-04 20:46:00 Re: Missing "CONSTRAINT" keyword in ADD CONSTRAINT form?
Previous Message PG Doc comments form 2023-12-04 20:28:53 Missing "CONSTRAINT" keyword in ADD CONSTRAINT form?