On Mon, 18 Aug 2025 at 09:09, jian he wrote:
> CREATE DOMAIN use ColConstraintElem.
> that's why we do not support syntax:
> ``create domain t1 as int not null not valid;``
>
> we also do not support column constraints NOT NULL NOT VALID.
> Like
> ``create table t(a int not null not valid);``
> w
On Thu, Aug 14, 2025 at 5:02 PM Kirill Reshke wrote:
>
> I have few observations.
> One is whether we should now support CREATE DOMAIN ... NOT NULL NOT
> VALID syntax? This could be a separate patch though.
>
in gram.y:
CreateDomainStmt:
CREATE DOMAIN_P any_name opt_as Typename ColQu
On 2025-Aug-14, Kirill Reshke wrote:
> reshke=# create domain dd as int;
> CREATE DOMAIN
> reshke=# create table dt(i int, c dd);
> CREATE TABLE
> reshke=# insert into dt values(1,null);
> INSERT 0 1
> reshke=# alter domain dd add constraint c not null not valid ;
> ALTER DOMAIN
> reshke=# update
On Thu, 14 Aug 2025 at 07:47, jian he wrote:
>
> hi.
> rebase and minor cosmetic change.
Hi!
It appears satisfactory to me.
I have few observations.
One is whether we should now support CREATE DOMAIN ... NOT NULL NOT
VALID syntax? This could be a separate patch though.
Second observation is just
hi.
rebase and minor cosmetic change.
From b87caa1b2f78d3f1e94e1055219c97e038d2fe61 Mon Sep 17 00:00:00 2001
From: jian he
Date: Thu, 14 Aug 2025 10:40:49 +0800
Subject: [PATCH v3 1/1] ALTER DOMAIN ADD NOT NULL NOT VALID
We have NOT NULL NO VALID for table constraints, we can make domain have
onname COLLATE "C";" to stabilize tests.
[0]
https://api.cirrus-ci.com/v1/artifact/task/6676676240736256/testrun/build/testrun/pg_upgrade/002_pg_upgrade/data/regression.diffs
From a840278f579b57cab4c13b91abfcc4f44a6d8a83 Mon Sep 17 00:00:00 2001
From: jian he
Date: Wed, 2
On 2025/5/21 18:44, jian he wrote:
hi.
attached patch is for $subject implementation
per https://www.postgresql.org/docs/current/sql-alterdomain.html
"""
Although ALTER DOMAIN ADD CONSTRAINT attempts to verify that existing stored
data satisfies the new constraint, this check is not bulletpr
things | integer | | not null not valid |
| CHECK (VALUE < 11)
From bdea7a60eab6e46d7f0b59b9a5602d6a2421f60d Mon Sep 17 00:00:00 2001
From: jian he
Date: Wed, 21 May 2025 18:43:17 +0800
Subject: [PATCH v1 1/1] ALTER DOMAIN ADD NOT NULL NOT VALID
we have NOT NULL NO VALID for table c