Re: [HACKERS] Optimization for index-only scans with filter conditions - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] Optimization for index-only scans with filter conditions
Date
Msg-id 12207.1481480418@sss.pgh.pa.us
Whole thread Raw
In response to [HACKERS] Optimization for index-only scans with filter conditions  (Mateusz Stefek <mateusz.stefek@gmail.com>)
List pgsql-hackers
Mateusz Stefek <mateusz.stefek@gmail.com> writes:
> Attached is a patch, which changes the order of the checks. I.e. the
> visibility of the row is confirmed only after the qual condition is
> evaluated to true.

This cannot be accepted, because it's unsafe to try to apply user
code to a dead tuple.  The tuple might reference toast data that's
not there anymore, or in the worst case it might not even match
the table rowtype anymore.

Even without that problem, I would think that whether it is a win or
not would be mighty workload-dependent.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] [sqlsmith] Crash in tsquery_rewrite/QTNBinary
Next
From: Jim Nasby
Date:
Subject: Re: [HACKERS] building HEAD on macos fails with #error no source ofrandom numbers configured