hadoop-hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ning Zhang (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HIVE-1002) multi-partition inserts
Date Wed, 31 Mar 2010 23:02:27 GMT

     [ https://issues.apache.org/jira/browse/HIVE-1002?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Ning Zhang updated HIVE-1002:
-----------------------------

    Attachment: HIVE-1002.patch

Uploading HIVE-1002.patch for inserting to dynamic partitions. Some examples are:

INSERT OVERWRITE TABLE T PARTITION (ds='2010-03-31', hr) select key, value, hr from srcpart
where ds is not null and hr is not null;

FROM srcpart
INSERT OVERWRITE TABLE T partition(ds='2010-03-31', hr) select key, value, hr where hr <
24
INSERT OVERWRITE TABLE T partition(ds='2010-03-31', hr = 'invalid') select key, value, hr
where hr >= 24;

More examples can be found in the .q files in the patch. 

> multi-partition inserts
> -----------------------
>
>                 Key: HIVE-1002
>                 URL: https://issues.apache.org/jira/browse/HIVE-1002
>             Project: Hadoop Hive
>          Issue Type: New Feature
>            Reporter: Zheng Shao
>            Assignee: Ning Zhang
>         Attachments: HIVE-1002.patch
>
>
> We should allow queries like this into a partitioned table:
> {code}
> CREATE TABLE (a STRING, b STRING, c STRING)
> PARTITIONED BY (ds STRING, ts STRING);
> INSERT OVERWRITE TABLE x PARTITION (ds = '2009-12-12')
> SELECT a, b, c, ts FROM xxx;
> {code}
> Basically, allowing users to overwrite multiple partitions at a time.
> The partition values specified in PARTITION part (if any) should be a prefix of the partition
keys.
> The rest of the partition keys goes to the end of the SELECT expression list.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message