You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Ziwei Liu (Jira)" <ji...@apache.org> on 2021/03/15 10:48:00 UTC

[jira] [Commented] (CALCITE-4525) Pull up predicate will lost some predicates when project contains same RexInputRef.

    [ https://issues.apache.org/jira/browse/CALCITE-4525?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17301577#comment-17301577 ] 

Ziwei Liu commented on CALCITE-4525:
------------------------------------

SELECT *
FROM (
  SELECT deptno AS x, deptno AS y
  FROM dept
  WHERE deptno= 20) left
join employee right on left.x=right.deptno
The RelMdPredicates.getPredicates got from left is y=20
Actually, x=20 is a predicate can be got, but lost

> Pull up predicate will lost some predicates when project contains same RexInputRef. 
> ------------------------------------------------------------------------------------
>
>                 Key: CALCITE-4525
>                 URL: https://issues.apache.org/jira/browse/CALCITE-4525
>             Project: Calcite
>          Issue Type: Improvement
>            Reporter: Ziwei Liu
>            Assignee: Ziwei Liu
>            Priority: Major
>
> If project like this a=$0, b=$0
> Pull up predicate is $0='a'
> when pull up through project, predicate will only contain b='a'



--
This message was sent by Atlassian Jira
(v8.3.4#803005)