Re: Corruption with IMMUTABLE functions in index expression.

From: Peter Geoghegan <pg(at)bowt(dot)ie>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, Prabhat Sahu <prabhat(dot)sahu(at)enterprisedb(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Corruption with IMMUTABLE functions in index expression.
Date: 2021-10-11 16:37:51
Message-ID: CAH2-Wzn69VjWpFzdrqJ7A8fZtS1YsnOEbgeWB5ynq0MazB4M_w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Oct 11, 2021 at 9:27 AM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Yeah. What is happening is that the function's SELECT on the subject
> table is trying to examine the not-yet-valid new index. While that could
> be argued to be a bug, I share David's lack of interest in fixing it,
> because I do not believe that there are any cases where a function that
> accesses an index's subject table is really going to be immutable.

Right. It might be different if this was something that users
sometimes expect will work, based on some plausible-though-wrong
understanding of expression indexes. But experience suggests that they
don't.

--
Peter Geoghegan

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Mark Dilger 2021-10-11 16:53:45 Re: BUG #17212: pg_amcheck fails on checking temporary relations
Previous Message Tom Lane 2021-10-11 16:36:34 Re: Corruption with IMMUTABLE functions in index expression.