Class ProjectJoinJoinRemoveRule

All Implemented Interfaces:
SubstitutionRule, TransformationRule

@Enclosing public class ProjectJoinJoinRemoveRule extends RelRule<ProjectJoinJoinRemoveRule.Config> implements SubstitutionRule
Planner rule that matches an Project on a Join and removes the left input of the join provided that the left input is also a left join if possible.

For instance,

select s.product_id, pc.product_id
 from sales as s
 left join product as p
   on s.product_id = p.product_id
 left join product_class pc
   on s.product_id = pc.product_id

becomes

select s.product_id, pc.product_id
 from sales as s
 left join product_class pc
   on s.product_id = pc.product_id
See Also: