Re: REPACK (CONCURRENTLY) doesn't handle invalid indexes

From: Álvaro Herrera <alvherre(at)kurilemu(dot)de>
To: Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com>
Cc: Christophe Pettus <xof(at)thebuild(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
Subject: Re: REPACK (CONCURRENTLY) doesn't handle invalid indexes
Date: 2026-09-08 07:25:25
Message-ID: ap-3KAqj28ED0TeA@alvherre.pgsql
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

Moving thread to -hackers.

On 2026-Aug-31, Zsolt Parragi wrote:

> On Mon, 31 Aug 2026, Christophe Pettus <xof(at)thebuild(dot)com> wrote:

> > I think your statement has its own answer embedded in it: It's
> > acceptable for REPACK, a brand-new command, to have different
> > behavior in the presence of invalid indexes specifically because it
> > would be a behavior change if we pushed that change to other
> > commands.
>
> But that's not exactly what happens here: currently REPACK and REPACK
> (CONCURRENTLY) behave differently in the presence of invalid indexes,
> and that is definitely a bug.

Yes, but I think the question is in which direction should we fix said
bug. My preference is to go for Kyotaro's suggestion: have both REPACK
and REPACK (CONCURRENTLY) raise an error with an invalid index, asking
the user to drop it.

Would anybody oppose that?

Maybe in pg20, barring complaints against this, we can propagate the
same behavior to CLUSTER and VACUUM FULL. (But that obviously need more
discussion.)

--
Álvaro Herrera Breisgau, Deutschland — https://www.EnterpriseDB.com/

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Fujii Masao 2026-09-08 08:34:17 Re: BUG #19644: byteaout, float8out and float4out are marked IMMUTABLE but depend on GUCs
Previous Message Richard Guo 2026-09-08 01:29:56 Re: BUG #19653: "variable not found in subplan target list" during planning with parallel parameterized nested loop,

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2026-09-08 07:30:09 Re: docs: Fixes for August 2026 minor release notes (v14-v17)
Previous Message Tatsuo Ishii 2026-09-08 07:18:26 Re: Row pattern recognition