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

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

GitHub user babokim opened a pull request:

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

    TAJO-1102: Self-join with a partitioned table returns wrong result data.

    

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

    $ git pull https://github.com/babokim/tajo TAJO-1102

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

    https://github.com/apache/tajo/pull/189.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 #189
    
----
commit 4886312282dbff392a84f5f6f3c7569e52f5f2e5
Author: HyoungJun Kim <[email protected]>
Date:   2014-10-07T12:56:28Z

    TAJO-1102: Self-join with a partitioned table returns wrong result data.

----


> Self-join with a partitioned table returns wrong result data.
> -------------------------------------------------------------
>
>                 Key: TAJO-1102
>                 URL: https://issues.apache.org/jira/browse/TAJO-1102
>             Project: Tajo
>          Issue Type: Bug
>            Reporter: Hyoungjun Kim
>            Assignee: Hyoungjun Kim
>            Priority: Minor
>
> See the following case.
> {code:sql}
> CREATE TABLE orders_partition
> (o_orderkey INT8, o_custkey INT8, o_totalprice FLOAT8, o_orderpriority TEXT,
>   o_clerk TEXT, o_shippriority INT4, o_comment TEXT) USING CSV WITH 
> ('csvfile.delimiter'='|')
> PARTITION BY COLUMN(o_orderdate TEXT, o_orderstatus TEXT);
> {code}
> {code:sql}
> select a.o_orderstatus, count(*) as cnt
> from orders_partition a
> inner join orders_partition b
> on a.o_orderdate = b.o_orderdate
>     and a.o_orderstatus = b.o_orderstatus
>     and a.o_orderkey = b.o_orderkey
> where a.o_orderdate='1995-02-21'
> and a.o_orderstatus in ('F')
> group by a.o_orderstatus;
> {code}
> Because of the where condition (where a.o_orderdate='1995-02-21 and 
> a.o_orderstatus in ('F')), orders_partition table aliased 'a' is small and 
> broadcast target table.
> In this case GlobalPlanner can't resolve which table is partitioned table.



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

Reply via email to