Uploaded image for project: 'Tajo'
  1. Tajo
  2. TAJO-939

Refactoring the column resolver in LogicalPlan

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.9.0
    • Component/s: Planner/Optimizer
    • Labels:
      None

      Description

      The main role of the column resolver is to find the exact column in a relation or a temporal column to which a variable name points. We have used a monolithic column resolver to deal with lots of cases.

      But, resolving a name should play different roles according to at which the name is placed.

      For example, 1) a column name in select list always points one of fields in relations, 2) a column name in WHERE clause can point to one of fields in relations or one of aliased temporal fields in select list. If there are duplicated, the column name firstly chooses the field in relations. 3) a column name in ORDER BY clause is similar to that in WHERE clause, but it firstly chooses one of aliased temporal fields in select list.

      The current column resolver does not consider the above rules. As a result, it works incorrectly in some cases where a sql statement includes the same name references, actually indicating one field in relation and one aliased temporal field in select list. We should fix it.

        Activity

        Hide
        githubbot ASF GitHub Bot added a comment -

        GitHub user hyunsik opened a pull request:

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

        TAJO-939: Refactoring the column resolver in LogicalPlan

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

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

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

        https://github.com/apache/tajo/pull/71.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 #71


        commit 8ff4d31297267547cf9111d6ac9fb9ed29e6e859
        Author: Hyunsik Choi <hyunsik@apache.org>
        Date: 2014-07-13T13:25:03Z

        Column Resolver should play different roles at each operation:

        First refactoring of resolver.

        commit 048c953768da9943c5d87c3f2e680f57e60aa571
        Author: Hyunsik Choi <hyunsik@apache.org>
        Date: 2014-07-13T17:45:23Z

        Column Resolver should play different roles at each operation:

        Refactored many of createEval to use NameResolver.

        commit cce2a566c1bca84d19e328d3b920c3b96af7bfe9
        Author: Hyunsik Choi <hyunsik@apache.org>
        Date: 2014-07-13T18:28:29Z

        Column Resolver should play different roles at each operation:

        Refactored CreateEval() except for join.

        commit 2d1a1d81631056711d5ff91d92f0f934c9561525
        Author: Hyunsik Choi <hyunsik@apache.org>
        Date: 2014-07-14T02:15:29Z

        Column Resolver should play different roles at each operation:

        Completely extracted the column resolver from LogicalPlan.

        commit ce12386d5e188679f48042ddc4262de59f9633be
        Author: Hyunsik Choi <hyunsik@apache.org>
        Date: 2014-07-14T04:53:42Z

        add comments.

        commit 0cac367998ce0399d0e31e6b5669ba74e1bb91a8
        Author: Hyunsik Choi <hyunsik@apache.org>
        Date: 2014-07-14T05:09:37Z

        added more unit tests.


        Show
        githubbot ASF GitHub Bot added a comment - GitHub user hyunsik opened a pull request: https://github.com/apache/tajo/pull/71 TAJO-939 : Refactoring the column resolver in LogicalPlan You can merge this pull request into a Git repository by running: $ git pull https://github.com/hyunsik/tajo TAJO-939 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/tajo/pull/71.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 #71 commit 8ff4d31297267547cf9111d6ac9fb9ed29e6e859 Author: Hyunsik Choi <hyunsik@apache.org> Date: 2014-07-13T13:25:03Z Column Resolver should play different roles at each operation: First refactoring of resolver. commit 048c953768da9943c5d87c3f2e680f57e60aa571 Author: Hyunsik Choi <hyunsik@apache.org> Date: 2014-07-13T17:45:23Z Column Resolver should play different roles at each operation: Refactored many of createEval to use NameResolver. commit cce2a566c1bca84d19e328d3b920c3b96af7bfe9 Author: Hyunsik Choi <hyunsik@apache.org> Date: 2014-07-13T18:28:29Z Column Resolver should play different roles at each operation: Refactored CreateEval() except for join. commit 2d1a1d81631056711d5ff91d92f0f934c9561525 Author: Hyunsik Choi <hyunsik@apache.org> Date: 2014-07-14T02:15:29Z Column Resolver should play different roles at each operation: Completely extracted the column resolver from LogicalPlan. commit ce12386d5e188679f48042ddc4262de59f9633be Author: Hyunsik Choi <hyunsik@apache.org> Date: 2014-07-14T04:53:42Z add comments. commit 0cac367998ce0399d0e31e6b5669ba74e1bb91a8 Author: Hyunsik Choi <hyunsik@apache.org> Date: 2014-07-14T05:09:37Z added more unit tests.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14873254

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanPreprocessor.java —
        @@ -197,6 +199,17 @@ public LogicalNode visitProjection(PreprocessContext ctx, Stack<Expr> stack, Pro
        }

        NamedExpr[] projectTargetExprs = expr.getNamedExprs();
        + NameRefInSelectListNormalizer normalizer = new NameRefInSelectListNormalizer();
        +
        + for (int i = 0; i < expr.getNamedExprs().length; i++) {
        + NamedExpr namedExpr = expr.getNamedExprs()[i];
        — End diff –

        It would be better use the above 'projectTargetExprs' variable.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14873254 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanPreprocessor.java — @@ -197,6 +199,17 @@ public LogicalNode visitProjection(PreprocessContext ctx, Stack<Expr> stack, Pro } NamedExpr[] projectTargetExprs = expr.getNamedExprs(); + NameRefInSelectListNormalizer normalizer = new NameRefInSelectListNormalizer(); + + for (int i = 0; i < expr.getNamedExprs().length; i++) { + NamedExpr namedExpr = expr.getNamedExprs() [i] ; — End diff – It would be better use the above 'projectTargetExprs' variable.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14873320

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -1192,8 +1204,12 @@ public ScanNode visitRelation(PlanContext context, Stack<Expr> stack, Relation e
        Set<String> newlyEvaluatedExprsReferences = new LinkedHashSet<String>();
        for (Iterator<NamedExpr> iterator = block.namedExprsMgr.getIteratorForUnevaluatedExprs(); iterator.hasNext() {
        NamedExpr rawTarget = iterator.next();
        +// if (rawTarget.getExpr().getType() == OpType.Column) {
        — End diff –

        Please remove commented out codes.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14873320 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -1192,8 +1204,12 @@ public ScanNode visitRelation(PlanContext context, Stack<Expr> stack, Relation e Set<String> newlyEvaluatedExprsReferences = new LinkedHashSet<String>(); for (Iterator<NamedExpr> iterator = block.namedExprsMgr.getIteratorForUnevaluatedExprs(); iterator.hasNext() { NamedExpr rawTarget = iterator.next(); +// if (rawTarget.getExpr().getType() == OpType.Column) { — End diff – Please remove commented out codes.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14873359

        — Diff: tajo-core/src/test/java/org/apache/tajo/engine/planner/TestLogicalPlanPreprocessor.java —
        @@ -0,0 +1,23 @@
        +/**
        + * Licensed to the Apache Software Foundation (ASF) under one
        + * or more contributor license agreements. See the NOTICE file
        + * distributed with this work for additional information
        + * regarding copyright ownership. The ASF licenses this file
        + * to you under the Apache License, Version 2.0 (the
        + * "License"); you may not use this file except in compliance
        + * with the License. You may obtain a copy of the License at
        + *
        + * http://www.apache.org/licenses/LICENSE-2.0
        + *
        + * Unless required by applicable law or agreed to in writing, software
        + * distributed under the License is distributed on an "AS IS" BASIS,
        + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
        + * See the License for the specific language governing permissions and
        + * limitations under the License.
        + */
        +
        +package org.apache.tajo.engine.planner;
        +
        +
        +public class TestLogicalPlanPreprocessor {
        — End diff –

        It seems that you intend to add some tests, but they are missed.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14873359 — Diff: tajo-core/src/test/java/org/apache/tajo/engine/planner/TestLogicalPlanPreprocessor.java — @@ -0,0 +1,23 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.tajo.engine.planner; + + +public class TestLogicalPlanPreprocessor { — End diff – It seems that you intend to add some tests, but they are missed.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-48889103

        Hi Hyunsik, I have a question.
        Do you have any rules for resolving names?
        If so, please share it. It will help us reviewing your patch.
        Thanks.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-48889103 Hi Hyunsik, I have a question. Do you have any rules for resolving names? If so, please share it. It will help us reviewing your patch. Thanks.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-48890108

        Thank you for the quick review.

        Unfortunately, I couldn't find the rule, and I expect that it is not specified in SQL standards because commercial DBMSs have different behaviors.

        So, I analyzed the behavior of PostgreSQL, and then I made it.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-48890108 Thank you for the quick review. Unfortunately, I couldn't find the rule, and I expect that it is not specified in SQL standards because commercial DBMSs have different behaviors. So, I analyzed the behavior of PostgreSQL, and then I made it.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14873851

        — Diff: tajo-core/src/test/java/org/apache/tajo/engine/planner/TestLogicalPlanPreprocessor.java —
        @@ -0,0 +1,23 @@
        +/**
        + * Licensed to the Apache Software Foundation (ASF) under one
        + * or more contributor license agreements. See the NOTICE file
        + * distributed with this work for additional information
        + * regarding copyright ownership. The ASF licenses this file
        + * to you under the Apache License, Version 2.0 (the
        + * "License"); you may not use this file except in compliance
        + * with the License. You may obtain a copy of the License at
        + *
        + * http://www.apache.org/licenses/LICENSE-2.0
        + *
        + * Unless required by applicable law or agreed to in writing, software
        + * distributed under the License is distributed on an "AS IS" BASIS,
        + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
        + * See the License for the specific language governing permissions and
        + * limitations under the License.
        + */
        +
        +package org.apache.tajo.engine.planner;
        +
        +
        +public class TestLogicalPlanPreprocessor {
        — End diff –

        Oops, I'll remove it soon.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14873851 — Diff: tajo-core/src/test/java/org/apache/tajo/engine/planner/TestLogicalPlanPreprocessor.java — @@ -0,0 +1,23 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.tajo.engine.planner; + + +public class TestLogicalPlanPreprocessor { — End diff – Oops, I'll remove it soon.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14873857

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -1192,8 +1204,12 @@ public ScanNode visitRelation(PlanContext context, Stack<Expr> stack, Relation e
        Set<String> newlyEvaluatedExprsReferences = new LinkedHashSet<String>();
        for (Iterator<NamedExpr> iterator = block.namedExprsMgr.getIteratorForUnevaluatedExprs(); iterator.hasNext() {
        NamedExpr rawTarget = iterator.next();
        +// if (rawTarget.getExpr().getType() == OpType.Column) {
        — End diff –

        I'll remove it.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14873857 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -1192,8 +1204,12 @@ public ScanNode visitRelation(PlanContext context, Stack<Expr> stack, Relation e Set<String> newlyEvaluatedExprsReferences = new LinkedHashSet<String>(); for (Iterator<NamedExpr> iterator = block.namedExprsMgr.getIteratorForUnevaluatedExprs(); iterator.hasNext() { NamedExpr rawTarget = iterator.next(); +// if (rawTarget.getExpr().getType() == OpType.Column) { — End diff – I'll remove it.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14873865

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanPreprocessor.java —
        @@ -197,6 +199,17 @@ public LogicalNode visitProjection(PreprocessContext ctx, Stack<Expr> stack, Pro
        }

        NamedExpr[] projectTargetExprs = expr.getNamedExprs();
        + NameRefInSelectListNormalizer normalizer = new NameRefInSelectListNormalizer();
        +
        + for (int i = 0; i < expr.getNamedExprs().length; i++) {
        + NamedExpr namedExpr = expr.getNamedExprs()[i];
        — End diff –

        Thank you for your suggestion. I'll do so.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14873865 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanPreprocessor.java — @@ -197,6 +199,17 @@ public LogicalNode visitProjection(PreprocessContext ctx, Stack<Expr> stack, Pro } NamedExpr[] projectTargetExprs = expr.getNamedExprs(); + NameRefInSelectListNormalizer normalizer = new NameRefInSelectListNormalizer(); + + for (int i = 0; i < expr.getNamedExprs().length; i++) { + NamedExpr namedExpr = expr.getNamedExprs() [i] ; — End diff – Thank you for your suggestion. I'll do so.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-48890833

        Thanks for your reply.
        If you can, would you mind sharing your rule?
        Actually, while reviewing, it is hard for me to check that resolve level is properly set.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-48890833 Thanks for your reply. If you can, would you mind sharing your rule? Actually, while reviewing, it is hard for me to check that resolve level is properly set.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-48907516

        Please see the following comments. I've just added the explanation about the motivation, all modes, and an example.
        https://github.com/apache/tajo/pull/71/files#diff-4f557feed9e12061e60da8dc979e7a5bR23

        I hope that it's helpful for your understanding.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-48907516 Please see the following comments. I've just added the explanation about the motivation, all modes, and an example. https://github.com/apache/tajo/pull/71/files#diff-4f557feed9e12061e60da8dc979e7a5bR23 I hope that it's helpful for your understanding.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-48981177

        Thanks!
        I'll review today.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-48981177 Thanks! I'll review today.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14945799

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -260,7 +262,8 @@ private void setRawTargets(PlanContext context, Target[] targets, String[] refer
        Target [] rawTargets = new Target[projection.getNamedExprs().length];
        for (int i = 0; i < projection.getNamedExprs().length; i++) {
        NamedExpr namedExpr = projection.getNamedExprs()[i];

        • EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr());
          + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(),
            • End diff –

        In setRawTargets(), raw expressions are found instead of references. So, it seems that resolving level should be set as RELS_ONLY. If I misunderstand, please let me know. Thanks.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14945799 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -260,7 +262,8 @@ private void setRawTargets(PlanContext context, Target[] targets, String[] refer Target [] rawTargets = new Target [projection.getNamedExprs().length] ; for (int i = 0; i < projection.getNamedExprs().length; i++) { NamedExpr namedExpr = projection.getNamedExprs() [i] ; EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr()); + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), End diff – In setRawTargets(), raw expressions are found instead of references. So, it seems that resolving level should be set as RELS_ONLY. If I misunderstand, please let me know. Thanks.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14946624

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -383,7 +386,7 @@ private EvalExprNode buildPlanForNoneFromStatement(PlanContext context, Stack<Ex

        for (int i = 0; i < targets.length; i++) {
        NamedExpr namedExpr = projection.getNamedExprs()[i];

        • EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr());
          + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), NameResolvingMode.RELS_ONLY);
            • End diff –

        Can RESL_ONLY level be applied for non-from statement?

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14946624 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -383,7 +386,7 @@ private EvalExprNode buildPlanForNoneFromStatement(PlanContext context, Stack<Ex for (int i = 0; i < targets.length; i++) { NamedExpr namedExpr = projection.getNamedExprs() [i] ; EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr()); + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), NameResolvingMode.RELS_ONLY); End diff – Can RESL_ONLY level be applied for non-from statement?
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r14946827

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -712,7 +718,8 @@ public LimitNode visitLimit(PlanContext context, Stack<Expr> stack, Limit limit)
        EvalNode firstFetNum;
        LogicalNode child;
        if (limit.getFetchFirstNum().getType() == OpType.Literal) {

        • firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum());
          + firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum(),
          + NameResolvingMode.RELS_ONLY);
            • End diff –

        Would you explain why RELS_ONLY is used for limit, please?

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r14946827 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -712,7 +718,8 @@ public LimitNode visitLimit(PlanContext context, Stack<Expr> stack, Limit limit) EvalNode firstFetNum; LogicalNode child; if (limit.getFetchFirstNum().getType() == OpType.Literal) { firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum()); + firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum(), + NameResolvingMode.RELS_ONLY); End diff – Would you explain why RELS_ONLY is used for limit, please?
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49059484

        Hi Hyunsik. I left some questions.
        Also, I have one more question.
        Would you mind explaining why legacy level is used for join? Is RELS_AND_SUBEXPRS sufficient such as where clause?

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49059484 Hi Hyunsik. I left some questions. Also, I have one more question. Would you mind explaining why legacy level is used for join? Is RELS_AND_SUBEXPRS sufficient such as where clause?
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r15042347

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -383,7 +386,7 @@ private EvalExprNode buildPlanForNoneFromStatement(PlanContext context, Stack<Ex

        for (int i = 0; i < targets.length; i++) {
        NamedExpr namedExpr = projection.getNamedExprs()[i];

        • EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr());
          + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), NameResolvingMode.RELS_ONLY);
            • End diff –

        As you know, non-from statement does not need to resolve any column because non-from statement means no table and no column reference.

        The main difference among the resolving modes is the priority and scope. It is enough to use the mode which has the correct priority and the scope. If possible, it would be nice if we use the mode the minimum scope. RELS_ONLY is the minimum scope one.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r15042347 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -383,7 +386,7 @@ private EvalExprNode buildPlanForNoneFromStatement(PlanContext context, Stack<Ex for (int i = 0; i < targets.length; i++) { NamedExpr namedExpr = projection.getNamedExprs() [i] ; EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr()); + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), NameResolvingMode.RELS_ONLY); End diff – As you know, non-from statement does not need to resolve any column because non-from statement means no table and no column reference. The main difference among the resolving modes is the priority and scope. It is enough to use the mode which has the correct priority and the scope. If possible, it would be nice if we use the mode the minimum scope. RELS_ONLY is the minimum scope one.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r15042369

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -712,7 +718,8 @@ public LimitNode visitLimit(PlanContext context, Stack<Expr> stack, Limit limit)
        EvalNode firstFetNum;
        LogicalNode child;
        if (limit.getFetchFirstNum().getType() == OpType.Literal) {

        • firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum());
          + firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum(),
          + NameResolvingMode.RELS_ONLY);
            • End diff –

        LIMIT has only constant. It does not have column reference. Its reason is the same that I commented for non-from statement.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r15042369 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -712,7 +718,8 @@ public LimitNode visitLimit(PlanContext context, Stack<Expr> stack, Limit limit) EvalNode firstFetNum; LogicalNode child; if (limit.getFetchFirstNum().getType() == OpType.Literal) { firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum()); + firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum(), + NameResolvingMode.RELS_ONLY); End diff – LIMIT has only constant. It does not have column reference. Its reason is the same that I commented for non-from statement.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r15056936

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/NameResolvingMode.java —
        @@ -0,0 +1,80 @@
        +/**
        + * Licensed to the Apache Software Foundation (ASF) under one
        + * or more contributor license agreements. See the NOTICE file
        + * distributed with this work for additional information
        + * regarding copyright ownership. The ASF licenses this file
        + * to you under the Apache License, Version 2.0 (the
        + * "License"); you may not use this file except in compliance
        + * with the License. You may obtain a copy of the License at
        + *
        + * http://www.apache.org/licenses/LICENSE-2.0
        + *
        + * Unless required by applicable law or agreed to in writing, software
        + * distributed under the License is distributed on an "AS IS" BASIS,
        + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
        + * See the License for the specific language governing permissions and
        + * limitations under the License.
        + */
        +
        +package org.apache.tajo.engine.planner.nameresolver;
        +
        +/**
        + *
        + * <h2>Motivation</h2>
        + *
        + * Please take a look at the following example query:
        + *
        + * <pre>
        + * select (l_orderkey + l_orderkey) l_orderkey from lineitem where l_orderkey > 2 order by l_orderkey;
        + * </pre>
        + *
        + * Although <code>l_orderkey</code> seems to be ambiguous, the above usages are available in commercial DBMSs.
        + * In order to eliminate the ambiguity, Tajo follows the behaviors of PostgreSQL.
        + *
        + * <h2>Resolving Modes</h2>
        + *
        + * From the behaviors of PostgreSQL, we found that there are three kinds of name resolving modes.
        + * Each definition is as follows:
        + *
        + * <ul>
        + * <li><b>RELS_ONLY</b> finds a column from the relations in the current block.
        + * <li><b>RELS_AND_SUBEXPRS</b> finds a column from the all relations in the current block and
        + * from aliased temporal fields; a temporal field means an explicitly aliased expression. If there are duplicated
        + * columns in the relation and temporal fields, this level firstly chooses the field in a relation.</li>
        + * <li><b>SUBEXPRS_AND_RELS</b> is very similar to <code>RELS_AND_SUBEXPRS</code>. The main difference is that it
        + * firstly chooses an aliased temporal field instead of the fields in a relation.</li>
        + * </ul>
        + *
        + * <h2>The relationship between resolving modes and operators</h3>
        + *
        + * <ul>
        + * <li>fields in select list are resolved in the REL_ONLY mode.</li>
        + * <li>fields in WHERE clause are resolved in the RELS_AND_SUBEXPRS mode.</li>
        + * <li>fields in GROUP BY, HAVING, ORDER BY, and LIMIT are resolved in the SUBEXPRS_AND_RELS mode.</li>
        — End diff –

        As you commented, fields in LIMIT are resolved in the REL_ONLY mode. Please fix it.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r15056936 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/NameResolvingMode.java — @@ -0,0 +1,80 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.tajo.engine.planner.nameresolver; + +/** + * + * <h2>Motivation</h2> + * + * Please take a look at the following example query: + * + * <pre> + * select (l_orderkey + l_orderkey) l_orderkey from lineitem where l_orderkey > 2 order by l_orderkey; + * </pre> + * + * Although <code>l_orderkey</code> seems to be ambiguous, the above usages are available in commercial DBMSs. + * In order to eliminate the ambiguity, Tajo follows the behaviors of PostgreSQL. + * + * <h2>Resolving Modes</h2> + * + * From the behaviors of PostgreSQL, we found that there are three kinds of name resolving modes. + * Each definition is as follows: + * + * <ul> + * <li><b>RELS_ONLY</b> finds a column from the relations in the current block. + * <li><b>RELS_AND_SUBEXPRS</b> finds a column from the all relations in the current block and + * from aliased temporal fields; a temporal field means an explicitly aliased expression. If there are duplicated + * columns in the relation and temporal fields, this level firstly chooses the field in a relation.</li> + * <li><b>SUBEXPRS_AND_RELS</b> is very similar to <code>RELS_AND_SUBEXPRS</code>. The main difference is that it + * firstly chooses an aliased temporal field instead of the fields in a relation.</li> + * </ul> + * + * <h2>The relationship between resolving modes and operators</h3> + * + * <ul> + * <li>fields in select list are resolved in the REL_ONLY mode.</li> + * <li>fields in WHERE clause are resolved in the RELS_AND_SUBEXPRS mode.</li> + * <li>fields in GROUP BY, HAVING, ORDER BY, and LIMIT are resolved in the SUBEXPRS_AND_RELS mode.</li> — End diff – As you commented, fields in LIMIT are resolved in the REL_ONLY mode. Please fix it.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r15056956

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -383,7 +386,7 @@ private EvalExprNode buildPlanForNoneFromStatement(PlanContext context, Stack<Ex

        for (int i = 0; i < targets.length; i++) {
        NamedExpr namedExpr = projection.getNamedExprs()[i];

        • EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr());
          + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), NameResolvingMode.RELS_ONLY);
            • End diff –

        Thanks Hyunsik!
        I misunderstood because it differs from the explanation of NameResolvingMode.
        I left another comment on it.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r15056956 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -383,7 +386,7 @@ private EvalExprNode buildPlanForNoneFromStatement(PlanContext context, Stack<Ex for (int i = 0; i < targets.length; i++) { NamedExpr namedExpr = projection.getNamedExprs() [i] ; EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr()); + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), NameResolvingMode.RELS_ONLY); End diff – Thanks Hyunsik! I misunderstood because it differs from the explanation of NameResolvingMode. I left another comment on it.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r15056981

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -712,7 +718,8 @@ public LimitNode visitLimit(PlanContext context, Stack<Expr> stack, Limit limit)
        EvalNode firstFetNum;
        LogicalNode child;
        if (limit.getFetchFirstNum().getType() == OpType.Literal) {

        • firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum());
          + firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum(),
          + NameResolvingMode.RELS_ONLY);
            • End diff –

        Thanks Hyunsik!
        I misunderstood because it differs from the explanation of NameResolvingMode.
        I left another comment on it.

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r15056981 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -712,7 +718,8 @@ public LimitNode visitLimit(PlanContext context, Stack<Expr> stack, Limit limit) EvalNode firstFetNum; LogicalNode child; if (limit.getFetchFirstNum().getType() == OpType.Literal) { firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum()); + firstFetNum = exprAnnotator.createEvalNode(context.plan, block, limit.getFetchFirstNum(), + NameResolvingMode.RELS_ONLY); End diff – Thanks Hyunsik! I misunderstood because it differs from the explanation of NameResolvingMode. I left another comment on it.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49550930

        @jihoonson I really appreciate your detailed review. I rebased the branch against the latest revision, and I reflected your comment. Please help to review it again.

        Thank you!

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49550930 @jihoonson I really appreciate your detailed review. I rebased the branch against the latest revision, and I reflected your comment. Please help to review it again. Thank you!
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on a diff in the pull request:

        https://github.com/apache/tajo/pull/71#discussion_r15207047

        — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java —
        @@ -260,7 +262,8 @@ private void setRawTargets(PlanContext context, Target[] targets, String[] refer
        Target [] rawTargets = new Target[projection.getNamedExprs().length];
        for (int i = 0; i < projection.getNamedExprs().length; i++) {
        NamedExpr namedExpr = projection.getNamedExprs()[i];

        • EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr());
          + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(),
            • End diff –

        name references in select list can be only actual column names. They are addressed in the manner at https://github.com/apache/tajo/pull/71/files#diff-c11c2244fea624cb7b08f6906d554cd4R470.

        In contrast, setRawTargets() in visitProjection should deal with actual fields as well as temporal fields generated by common subexpression elimination. So, it should use RELS_AND_SUBEXPRS.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on a diff in the pull request: https://github.com/apache/tajo/pull/71#discussion_r15207047 — Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java — @@ -260,7 +262,8 @@ private void setRawTargets(PlanContext context, Target[] targets, String[] refer Target [] rawTargets = new Target [projection.getNamedExprs().length] ; for (int i = 0; i < projection.getNamedExprs().length; i++) { NamedExpr namedExpr = projection.getNamedExprs() [i] ; EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr()); + EvalNode evalNode = exprAnnotator.createEvalNode(plan, block, namedExpr.getExpr(), End diff – name references in select list can be only actual column names. They are addressed in the manner at https://github.com/apache/tajo/pull/71/files#diff-c11c2244fea624cb7b08f6906d554cd4R470 . In contrast, setRawTargets() in visitProjection should deal with actual fields as well as temporal fields generated by common subexpression elimination. So, it should use RELS_AND_SUBEXPRS.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49688721

        @jihoonson Join requires more complex conditions. So, I need to clean up the name resolving logic for join condition, and I need more time for this job. If you are Ok, I'll do it in another Jira.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49688721 @jihoonson Join requires more complex conditions. So, I need to clean up the name resolving logic for join condition, and I need more time for this job. If you are Ok, I'll do it in another Jira.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49688899

        Rebased.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49688899 Rebased.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49690843

        Thanks for your reply!
        Currently, the latest patch looks good, and +1!

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49690843 Thanks for your reply! Currently, the latest patch looks good, and +1!
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user jihoonson commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49690877

        And please create a Jira issue for name resolution of join condition.
        Thanks!

        Show
        githubbot ASF GitHub Bot added a comment - Github user jihoonson commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49690877 And please create a Jira issue for name resolution of join condition. Thanks!
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49691285

        Thank you very much. I'll create the jira.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49691285 Thank you very much. I'll create the jira.
        Hide
        hyunsik Hyunsik Choi added a comment -

        committed it to master branch.

        Show
        hyunsik Hyunsik Choi added a comment - committed it to master branch.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user asfgit closed the pull request at:

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

        Show
        githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/tajo/pull/71
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Tajo-master-build #309 (See https://builds.apache.org/job/Tajo-master-build/309/)
        TAJO-939: Refactoring the column resolver in LogicalPlan. (hyunsik: rev 862435bc9622f9a8dde07417158b904554c36e60)

        • tajo-catalog/tajo-catalog-common/src/main/java/org/apache/tajo/catalog/Schema.java
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverBySubExprsAndRels.java
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanPreprocessor.java
        • tajo-core/src/test/resources/results/TestSelectQuery/testNonQualifiedNames.result
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverByLegacy.java
        • tajo-core/src/test/java/org/apache/tajo/engine/query/TestCaseByCases.java
        • CHANGES
        • tajo-core/src/test/java/org/apache/tajo/engine/eval/TestEvalTreeUtil.java
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/NameResolver.java
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverByRelsAndSubExprs.java
        • tajo-core/src/test/resources/queries/TestSelectQuery/testSelectColumnAliasExistingInRelation1.sql
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java
        • tajo-core/src/test/resources/results/TestCaseByCases/testTAJO917Case1.result
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlan.java
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/ExprNormalizer.java
        • tajo-core/src/test/resources/results/TestSelectQuery/testSelectColumnAliasExistingInRelation1.result
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverByRels.java
        • tajo-core/src/test/resources/queries/TestCaseByCases/testTAJO917Case1.sql
        • tajo-core/src/test/resources/queries/TestSelectQuery/testNonQualifiedNames.sql
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/NameResolvingMode.java
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/logical/TableSubQueryNode.java
        • tajo-core/src/test/resources/results/TestSelectQuery/testSelectColumnAliasExistingInRelation2.result
        • tajo-core/src/main/java/org/apache/tajo/engine/planner/ExprAnnotator.java
        • tajo-core/src/test/resources/queries/TestSelectQuery/testSelectColumnAliasExistingInRelation2.sql
        • tajo-core/src/test/java/org/apache/tajo/engine/query/TestSelectQuery.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Tajo-master-build #309 (See https://builds.apache.org/job/Tajo-master-build/309/ ) TAJO-939 : Refactoring the column resolver in LogicalPlan. (hyunsik: rev 862435bc9622f9a8dde07417158b904554c36e60) tajo-catalog/tajo-catalog-common/src/main/java/org/apache/tajo/catalog/Schema.java tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverBySubExprsAndRels.java tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanPreprocessor.java tajo-core/src/test/resources/results/TestSelectQuery/testNonQualifiedNames.result tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverByLegacy.java tajo-core/src/test/java/org/apache/tajo/engine/query/TestCaseByCases.java CHANGES tajo-core/src/test/java/org/apache/tajo/engine/eval/TestEvalTreeUtil.java tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/NameResolver.java tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverByRelsAndSubExprs.java tajo-core/src/test/resources/queries/TestSelectQuery/testSelectColumnAliasExistingInRelation1.sql tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java tajo-core/src/test/resources/results/TestCaseByCases/testTAJO917Case1.result tajo-core/src/main/java/org/apache/tajo/engine/planner/LogicalPlan.java tajo-core/src/main/java/org/apache/tajo/engine/planner/ExprNormalizer.java tajo-core/src/test/resources/results/TestSelectQuery/testSelectColumnAliasExistingInRelation1.result tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/ResolverByRels.java tajo-core/src/test/resources/queries/TestCaseByCases/testTAJO917Case1.sql tajo-core/src/test/resources/queries/TestSelectQuery/testNonQualifiedNames.sql tajo-core/src/main/java/org/apache/tajo/engine/planner/nameresolver/NameResolvingMode.java tajo-core/src/main/java/org/apache/tajo/engine/planner/logical/TableSubQueryNode.java tajo-core/src/test/resources/results/TestSelectQuery/testSelectColumnAliasExistingInRelation2.result tajo-core/src/main/java/org/apache/tajo/engine/planner/ExprAnnotator.java tajo-core/src/test/resources/queries/TestSelectQuery/testSelectColumnAliasExistingInRelation2.sql tajo-core/src/test/java/org/apache/tajo/engine/query/TestSelectQuery.java
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/71#issuecomment-49709961

        I've made the jira to clean up the name resolving logic for join condition.
        https://issues.apache.org/jira/browse/TAJO-971

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/71#issuecomment-49709961 I've made the jira to clean up the name resolving logic for join condition. https://issues.apache.org/jira/browse/TAJO-971

          People

          • Assignee:
            hyunsik Hyunsik Choi
            Reporter:
            hyunsik Hyunsik Choi
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development