Re: REPACK (CONCURRENTLY) loses missing values of columns added without a rewrite

From: shihao zhong <zhong950419(at)gmail(dot)com>
To: Sami Imseih <samimseih(dot)pg(at)gmail(dot)com>
Cc: Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: REPACK (CONCURRENTLY) loses missing values of columns added without a rewrite
Date: 2026-09-23 04:37:03
Message-ID: CAGRkXqSKbn3qPDis1mU=fwtMPejCYACwYAOkbAXFmSS5MJBi1w@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Sami,

v2 fixes the issue you mentioned.

I think It also fixes another case. If the added column is in the replica
identity index, REPACK looks up the row with a NULL key. That fails the
Assert in find_target_tuple(), or gives "could not find target tuple"
without assertions. Adding this to the test covers it:

CREATE UNIQUE INDEX repack_test_i_c_idx ON repack_test (i, c);
ALTER TABLE repack_test REPLICA IDENTITY USING INDEX
repack_test_i_c_idx;

Thanks,
Shihao

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2026-09-23 04:38:11 Re: Distinguish publication exclusions in object addresses
Previous Message shveta malik 2026-09-23 04:35:27 Re: sequencesync worker race with REFRESH SEQUENCES