Re: Removing INNER JOINs - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Removing INNER JOINs
Date
Msg-id 20141203154559.GA2456@alap3.anarazel.de
Whole thread Raw
In response to Re: Removing INNER JOINs  (Simon Riggs <simon@2ndQuadrant.com>)
List pgsql-hackers
On 2014-12-03 11:30:32 +0000, Simon Riggs wrote:
> I guess we need an Option node. Tom and I discussed that about an aeon ago.
> 
> The Option node has a plan for each situation. At execution time, we
> make the test specified in the plan and then select the appropriate
> subplan.
> 
> That way we can see what is happening in the plan and the executor
> doesn't need to edit anything.

Given David's result where he noticed a performance impact due to the
additional branch in the join code - which I still have a bit of a hard
time to believe - it seems likely that a whole separate node that has to
pass stuff around will be more expensive.

I think the switch would actually have to be done in ExecInitNode() et
al. David, if you essentially take your previous solution and move the
if into ExecInitNode(), does it work well?

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



pgsql-hackers by date:

Previous
From: Sameer Kumar
Date:
Subject: Re: Using pg_rewind for differential backup
Next
From: Robert Haas
Date:
Subject: Re: Removing INNER JOINs