Re: Catalog domain not-null constraints - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: Catalog domain not-null constraints
Date
Msg-id 96cefb54-61e5-45d8-b94b-da57fc1b1b92@eisentraut.org
Whole thread Raw
In response to Re: Catalog domain not-null constraints  (Aleksander Alekseev <aleksander@timescale.com>)
Responses Re: Catalog domain not-null constraints
List pgsql-hackers
On 23.11.23 14:13, Aleksander Alekseev wrote:
> =# create domain connotnull1 integer;
> =# create domain connotnull2 integer;
> =# alter domain connotnull1 add not null value;
> =# alter domain connotnull2 set not null;
> =# \dD
> ERROR:  unexpected null value in cached tuple for catalog
> pg_constraint column conkey

Yeah, for domain not-null constraints pg_constraint.conkey is indeed 
null.  Should we put something in there?

Attached is an updated patch that avoids the error by taking a separate 
code path for domain constraints in ruleutils.c.  But maybe there is 
another way to arrange this.
Attachment

pgsql-hackers by date:

Previous
From: David Rowley
Date:
Subject: Re: Memory consumed by paths during partitionwise join planning
Next
From: Masahiko Sawada
Date:
Subject: Re: Testing autovacuum wraparound (including failsafe)