On 2024-07-29 13:02 +0200, PG Doc comments form wrote: > In the Synopsis section of > https://www.postgresql.org/docs/current/sql-alterdomain.html > this is incorrect (incomplete): > "ALTER DOMAIN name ADD domain_constraint [ NOT VALID ]" > It should be > "ALTER DOMAIN name ADD CONSTRAINT domain_constraint [ NOT VALID ]"
No, the docs are correct. domain_constraint refers to this syntax defined by CREATE DOMAIN: "where constraint is: [ CONSTRAINT constraint_name ] { NOT NULL | NULL | CHECK (expression) }" Also, PG 17 renames this to "domain_constraint" with commit 9895b35cb8 to align ALTER DOMAIN with CREATE DOMAIN. -- Erik