Re: bug when apply fast default mechanism for adding new column over domain with default value

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: jian he <jian(dot)universality(at)gmail(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: bug when apply fast default mechanism for adding new column over domain with default value
Date: 2025-03-03 18:38:38
Message-ID: 4060266.1741027118@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I wrote:
> jian he <jian(dot)universality(at)gmail(dot)com> writes:
>> within ATExecAddColumn, we can
>> if (!missingIsNull)
>> StoreAttrMissingVal(rel, attribute->attnum, missingval, missingIsNull);
>> to save some cycles?

> Probably not really worth it: surely that's going to be a very
> infrequent edge case.

On second thought, it is worth doing like that, not on speed
grounds but because we can make StoreAttrMissingVal simpler
by not handling the is-null case at all.

Pushed with that adjustment and some other minor polishing.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Antonin Houska 2025-03-03 18:40:27 Re: why there is not VACUUM FULL CONCURRENTLY?
Previous Message Fujii Masao 2025-03-03 18:17:54 Re: Change log level for notifying hot standby is waiting non-overflowed snapshot