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

ASF GitHub Bot commented on TAJO-1099:
--------------------------------------

GitHub user hyunsik opened a pull request:

    https://github.com/apache/tajo/pull/185

    TAJO-1099: LogicalPlanner::convertDataType causes NPE in some cases.

    So far, ExprTestBase has not passed through TypeDeterminant in 
LogicalPlanPreprocessor. So, unit tests haven't caused this problems. 
    
    I fixed the bug and modified LogicalPlanPreprocessor to pass 
TypeDeterminant in LogicalPlanPreprocessor. As a result, even though this patch 
does not include any unit tests, it is same as all ExprTestBase tests verify 
this problem.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/hyunsik/tajo TAJO-1099

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/tajo/pull/185.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #185
    
----
commit 98a9cfa4778c1bbd035157865e28f57c10622cee
Author: Hyunsik Choi <[email protected]>
Date:   2014-10-07T17:09:20Z

    TAJO-1099: LogicalPlanner::convertDataType causes NPE in some cases.

----


> LogicalPlanner::convertDataType causes NPE in some cases.
> ---------------------------------------------------------
>
>                 Key: TAJO-1099
>                 URL: https://issues.apache.org/jira/browse/TAJO-1099
>             Project: Tajo
>          Issue Type: Bug
>          Components: planner/optimizer
>    Affects Versions: 0.8.0
>            Reporter: Hyunsik Choi
>            Assignee: Hyunsik Choi
>             Fix For: 0.9.0
>
>
> {code:sql}
> SELECT x, p::interval, to_timestamp(time), to_timestamp(utc / 1000) FROM 
> (SELECT u.x, time - (utc / 1000) as p, time, utc FROM T1 l JOIN T2 u ON l.x = 
> u.x) T WHERE p < 0
> {code}
> {noformat}
> 2014-10-06 15:17:42,334 ERROR org.apache.tajo.master.GlobalEngine:
> Stack Trace:
> java.lang.NullPointerException
>   at 
> org.apache.tajo.engine.planner.LogicalPlanner.convertDataType(LogicalPlanner.java:1836)
>   at 
> org.apache.tajo.engine.planner.TypeDeterminant.visitUnaryOperator(TypeDeterminant.java:60)
>   at 
> org.apache.tajo.engine.planner.TypeDeterminant.visitUnaryOperator(TypeDeterminant.java:37)
>   at 
> org.apache.tajo.engine.planner.SimpleAlgebraVisitor.visit(SimpleAlgebraVisitor.java:34)
>   at 
> org.apache.tajo.engine.planner.TypeDeterminant.determineDataType(TypeDeterminant.java:46)
>   at 
> org.apache.tajo.engine.planner.LogicalPlanPreprocessor.visitProjection(LogicalPlanPreprocessor.java:208)
>   at 
> org.apache.tajo.engine.planner.LogicalPlanPreprocessor.visitProjection(LogicalPlanPreprocessor.java:40)
>   at 
> org.apache.tajo.engine.planner.BaseAlgebraVisitor.visit(BaseAlgebraVisitor.java:55)
>   at 
> org.apache.tajo.engine.planner.LogicalPlanner.createPlan(LogicalPlanner.java:129)
>   at 
> org.apache.tajo.engine.planner.LogicalPlanner.createPlan(LogicalPlanner.java:119)
>   at 
> org.apache.tajo.master.GlobalEngine.createLogicalPlan(GlobalEngine.java:497)
> {noformat}



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

Reply via email to