Thanks Zain,

I'll take a look at setting the cost.


________________________________
From: Zain Humayun <[email protected]>
Sent: Monday, August 14, 2017 12:45:17 PM
To: [email protected]
Subject: Re: Multiple Rules Matching LogicalProject

I'm not too sure how the planner deals with tie breakers between two plans,
but if you prefer ProjectB to ProjectA, then giving ProjectB a lower cost
than ProjectA should result in the planner choosing ProjectB.

Zain.

On Mon, Aug 14, 2017 at 12:39 PM, Timothy Farkas <[email protected]> wrote:

> Hi All,
>
> I'm new to Calcite, so this may be a silly question. How can I control the
> behavior of the VolcanoPlanner when two rules match the same relation node
> and transform it? I am seeing an issue where I have two Rules (RuleA and
> RuleB) which match a LogicalProject relation node. When RuleA matches it
> transforms the relational node to a ProjectA node, and when RuleB matches
> it transforms the relational node to a ProjectB node. However, the output
> of the planner always has ProjectA nodes and never has ProjectB nodes. How
> can I tell the planner than I prefer ProjectB nodes over ProjectA nodes?
>
> I am using the Apache Drill version of Calcite which is based on Calcite
> 1.4
>
> Thanks,
> Tim
>

Reply via email to