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

Navis commented on HIVE-5690:
-----------------------------

[~xuefuz] Yes, bad example made just for showing the syntax. I cannot remember 
exactly but it was originated from a query something like (still dummy),
{noformat}
from LV explode_map(...) from K
insert into table X1 select to_map('a',a,'b',b,'c', c) from (select a, 
count(b), sum(c) group by a) A
insert into table X2 select to_map('b',b,'d',d,'e', e) from (select b, 
count(d), sum(e) group by b) B
{noformat}

> Support subquery for single sourced multi query
> -----------------------------------------------
>
>                 Key: HIVE-5690
>                 URL: https://issues.apache.org/jira/browse/HIVE-5690
>             Project: Hive
>          Issue Type: Improvement
>          Components: Query Processor
>            Reporter: Navis
>            Assignee: Navis
>            Priority: Minor
>         Attachments: D13791.1.patch, HIVE-5690.10.patch.txt, 
> HIVE-5690.11.patch.txt, HIVE-5690.12.patch.txt, HIVE-5690.2.patch.txt, 
> HIVE-5690.3.patch.txt, HIVE-5690.4.patch.txt, HIVE-5690.5.patch.txt, 
> HIVE-5690.6.patch.txt, HIVE-5690.7.patch.txt, HIVE-5690.8.patch.txt, 
> HIVE-5690.9.patch.txt
>
>
> Single sourced multi (insert) query is very useful for various ETL processes 
> but it does not allow subqueries included. For example, 
> {noformat}
> explain from src 
> insert overwrite table x1 select * from (select distinct key,value) b order 
> by key
> insert overwrite table x2 select * from (select distinct key,value) c order 
> by value;
> {noformat}



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

Reply via email to