|From:||Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>|
|Subject:||Re: Index-only scans vs. partially-retrievable indexes|
|Views:||Raw Message | Whole Thread | Download mbox | Resend email|
> Unless somebody's got a better idea, I'll push forward with making
> this happen.
Here's a proposed patch for that. I ended up reverting the code
changes of 4ace45677 in favor of an alternative I'd considered
previously, which is to mark the indextlist elements as resjunk
if they're non-retrievable, and then make setrefs.c deal with
not relying on those elements. This avoids the EXPLAIN breakage
I showed, since now we still have the indextlist elements needed
to interpret the indexqual and indexorderby expressions.
0001 is what I propose to back-patch (modulo putting the new
IndexOnlyScan.recheckqual field at the end, in the back branches).
In addition, it seems to me that we can simplify check_index_only()
by reverting b5febc1d1's changes, because we've now been forced to
put in a non-half-baked solution for the problem it addressed.
That's 0002 attached. I'd be inclined not to back-patch that though.
regards, tom lane
|Next Message||Thomas Munro||2022-01-03 01:47:05||Re: daitch_mokotoff module|
|Previous Message||Andres Freund||2022-01-02 21:34:45||Re: Add jsonlog log_destination for JSON server logs|