Re: Surprising SeqScan of appendRel that can't contribute any rows to the result - Mailing list pgsql-bugs

From Tom Lane
Subject Re: Surprising SeqScan of appendRel that can't contribute any rows to the result
Date
Msg-id 2549068.1734486021@sss.pgh.pa.us
Whole thread Raw
In response to Re: Surprising SeqScan of appendRel that can't contribute any rows to the result  (David Rowley <dgrowleyml@gmail.com>)
List pgsql-bugs
David Rowley <dgrowleyml@gmail.com> writes:
> On Wed, 18 Dec 2024 at 12:17, Dmytro Astapov <dastapov@gmail.com> wrote:
>> Surprisingly, this does SeqScan on partB in NestedLoops over some_ids with a filter `some_ids.id = NULL::bigint`:

> TL;DR is it's not a bug and expected behaviour.

The particular case shown here might be fixable by re-applying
eval_const_expressions after we've derived the pushed-down qual.
Most of the time that'd be a waste of cycles though, and I'm
not sure how often it would help.

            regards, tom lane



pgsql-bugs by date:

Previous
From: Dmytro Astapov
Date:
Subject: Re: Surprising SeqScan of appendRel that can't contribute any rows to the result
Next
From: Tom Lane
Date:
Subject: Re: Not able to restore database - error: could not decompress data: Allocation error : not enough memory