Re: pg_dump does not dump domain not-null constraint's comments - Mailing list pgsql-hackers

From jian he
Subject Re: pg_dump does not dump domain not-null constraint's comments
Date
Msg-id CACJufxHEX9nboSZSz_Qw1_Kwvnvdfieqn_rCRHcwEqyGEEzNAA@mail.gmail.com
Whole thread Raw
In response to Re: pg_dump does not dump domain not-null constraint's comments  (Álvaro Herrera <alvherre@kurilemu.de>)
List pgsql-hackers
On Fri, Jul 18, 2025 at 5:11 AM Álvaro Herrera <alvherre@kurilemu.de> wrote:
>
> Anyway, here's a patch.
>
one minor issue in getDomainConstraints:

 for (int i = 0, j = 0; i < ntups; i++)
{
        char        contype = (PQgetvalue(res, i, i_contype))[0];
        ....
        constraint->contype = *(PQgetvalue(res, i, i_contype));
}

for the same code simplicity,
``constraint->contype = *(PQgetvalue(res, i, i_contype));``
can change to
`` constraint->contype = contype;  ``
?
other than that, looks good to me.



pgsql-hackers by date:

Previous
From: feichanghong
Date:
Subject: Even when the data is already ordered, MergeAppend still adds a Sort node
Next
From: Sami Imseih
Date:
Subject: Re: Proposal to Enable/Disable Index using ALTER INDEX