Re: BUG #19435: Error: "No relation entry for relid 2" Triggered by Complex Join with Self-Referencing Tables - Mailing list pgsql-bugs

From Andrei Lepikhov
Subject Re: BUG #19435: Error: "No relation entry for relid 2" Triggered by Complex Join with Self-Referencing Tables
Date
Msg-id a78fe5d4-e6b8-4b3c-9cfd-135edbb68e4c@gmail.com
Whole thread Raw
In response to Re: BUG #19435: Error: "No relation entry for relid 2" Triggered by Complex Join with Self-Referencing Tables  (Alexander Korotkov <aekorotkov@gmail.com>)
Responses Re: BUG #19435: Error: "No relation entry for relid 2" Triggered by Complex Join with Self-Referencing Tables
List pgsql-bugs
On 18/3/26 09:40, Alexander Korotkov wrote:
> What about being more generic and call ChangeVarNodes_walker() for the
> node in ChangeVarNodesWalkExpression()?  It also works with out case
> and avoids code duplication.
I’ve reached the same conclusion. We lost a possible case when the 
RestrictInfo→clause contains a bare Var that isn’t pushed into either 
the left or right subtree.
I think we can fix this by replacing the expression walker with 
ChangeVarNodes_walker().
What is the reason for the second change? Tender, can you show us how to 
reproduce the issue so we can support your update to 
restrict_infos_logically_equal? If we include it, we should add a test.

-- 
regards, Andrei Lepikhov,
pgEdge
Attachment

pgsql-bugs by date:

Previous
From: Ana Almeida
Date:
Subject: Segmentation fault in PostgreSQL 17.7 during REINDEX TABLE CONCURRENTLY
Next
From: Alexander Korotkov
Date:
Subject: Re: BUG #19435: Error: "No relation entry for relid 2" Triggered by Complex Join with Self-Referencing Tables