You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Ted Xu (JIRA)" <ji...@apache.org> on 2016/06/21 07:57:57 UTC

[jira] [Commented] (CALCITE-1299) Reference type of Pulled Up Predicates is not handled properly

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

Ted Xu commented on CALCITE-1299:
---------------------------------

I'd like to take this one. 

The root cause seems to be in RexPermuteInputsShuttle. I'll submit a patch when I'm ready.

> Reference type of Pulled Up Predicates is not handled properly
> --------------------------------------------------------------
>
>                 Key: CALCITE-1299
>                 URL: https://issues.apache.org/jira/browse/CALCITE-1299
>             Project: Calcite
>          Issue Type: Bug
>          Components: core
>    Affects Versions: next
>            Reporter: Ted Xu
>            Assignee: Julian Hyde
>            Priority: Critical
>             Fix For: 1.9.0
>
>
> RelMdPredicates is not handling reference types well. Noticing the following query:
> {code:title=query.sql|borderStyle=solid}
> SELECT * FROM
> (SELECT * FROM src) o JOIN (SELECT "foo" as key, value FROM src1) o1
> ON o.key = o1.key 
> {code}
> The right side predicate is [key -> "foo"] with key type VARCHAR NOT NULL, the very type is not matching the input reference from the left side, causing error when applying JoinPushTransitivePredicatesRule.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)