On Mon, Oct 11, 2021 at 9:27 AM Tom Lane <t...@sss.pgh.pa.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