Re: pg_dump does not dump domain not-null constraint's comments

From: jian he <jian(dot)universality(at)gmail(dot)com>
To: Álvaro Herrera <alvherre(at)kurilemu(dot)de>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pg_dump does not dump domain not-null constraint's comments
Date: 2025-07-18 14:44:26
Message-ID: CACJufxHEX9nboSZSz_Qw1_Kwvnvdfieqn_rCRHcwEqyGEEzNAA@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jul 18, 2025 at 5:11 AM Álvaro Herrera <alvherre(at)kurilemu(dot)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.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Sami Imseih 2025-07-18 15:40:46 Re: Proposal to Enable/Disable Index using ALTER INDEX
Previous Message feichanghong 2025-07-18 14:37:56 Even when the data is already ordered, MergeAppend still adds a Sort node