Hyunsik Choi created TAJO-560:
---------------------------------

             Summary: CTAS PARTITION BY with UNION  can cause invalid global 
plan
                 Key: TAJO-560
                 URL: https://issues.apache.org/jira/browse/TAJO-560
             Project: Tajo
          Issue Type: Bug
          Components: distributed query plan, planner/optimizer
            Reporter: Hyunsik Choi
             Fix For: 0.8-incubating


Take a look at the following query. This kind of queries can cause invalid 
distributed plans.
{code}
create table testCtasWithUnion (col1 int4, col2 int4) partition by column(key 
float8) as

select
  *
from (

select
  sum(l_orderkey) as total1,
  avg(l_partkey) as total2,
  l_quantity as key
from
  lineitem
group by
  l_quantity
order by
  l_quantity
limit
  3

union

select
  sum(l_orderkey) as total1,
  avg(l_partkey) as total2,
  l_quantity as key
from
  lineitem
group by
  l_quantity
order by
  l_quantity
limit
  3

) t1;
{code}



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Reply via email to