From: | Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com> |
---|---|
To: | Álvaro Herrera <alvherre(at)kurilemu(dot)de> |
Cc: | jian he <jian(dot)universality(at)gmail(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: pg_dump misses comments on NOT NULL constraints |
Date: | 2025-06-26 11:29:55 |
Message-ID: | 510868af-11e0-4173-a8eb-aa8c712abc7c@oss.nttdata.com |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2025/06/26 0:45, Álvaro Herrera wrote:
> On 2025-Jun-26, Fujii Masao wrote:
>
>> CREATE TABLE ctlt1_inh (LIKE ctlt1 INCLUDING CONSTRAINTS INCLUDING COMMENTS) INHERITS (ctlt1);
>> \d+ ctlt1_inh
>> -SELECT description FROM pg_description, pg_constraint c WHERE classoid = 'pg_constraint'::regclass AND objoid = c.oid AND c.conrelid = 'ctlt1_inh'::regclass;
>> +SELECT conname, description FROM pg_description, pg_constraint c WHERE classoid = 'pg_constraint'::regclass AND objoid = c.oid AND c.conrelid = 'ctlt1_inh'::regclass ORDER BY conname COLLATE "C";
>>
>> However, since ctlt1_inh is created with INCLUDING COMMENTS, this test
>> doesn't seem to demonstrate the case you mentioned — that comments on
>> not-null constraints are copied even without INCLUDING CONSTRAINTS.
>> Am I misunderstanding?
>
> Hmm, yeah the case I wanted to modify was for ctlt12_comments which does
> INCLUDING COMMENTS without constraints, apologies. In that case it's
> better to modify ctlt2 instead, as shown here.
Thanks for updating the tests!
I've incorporated the changes into the patch and committed it.
Regards,
--
Fujii Masao
NTT DATA Japan Corporation
From | Date | Subject | |
---|---|---|---|
Next Message | Jakub Wartak | 2025-06-26 11:31:39 | Re: NUMA shared memory interleaving |
Previous Message | Jelte Fennema-Nio | 2025-06-26 10:43:44 | Re: PG18 protocol version |