You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Ruslan Dautkhanov (JIRA)" <ji...@apache.org> on 2016/09/20 03:06:20 UTC

[jira] [Created] (HIVE-14795) ALTER TABLE ... RENAME [OVERWRITE] [TO] to overwrite existing table

Ruslan Dautkhanov created HIVE-14795:
----------------------------------------

             Summary: ALTER TABLE ... RENAME [OVERWRITE] [TO] to overwrite existing table
                 Key: HIVE-14795
                 URL: https://issues.apache.org/jira/browse/HIVE-14795
             Project: Hive
          Issue Type: Improvement
          Components: Hive
    Affects Versions: 2.1.0, 2.0.0, 1.1.0, 1.2.0
            Reporter: Ruslan Dautkhanov


It would be great to Have in OVERWRITE option in Hive's rename command:

ALTER TABLE ... RENAME [OVERWRITE] [TO] to overwrite existing table, if it exists.

There are many commands like DROP TABLE IF EXISTS, LOAD DATA .. OVERWRITE that tell how to deal if table already exists.

We currently have to check in our ETL pipelines (outside of Hive) if table already exists and call different actions depending on that result.

It would simplify that logic quite a bit.

Closest in functionaility I found in MySQL: http://bugs.mysql.com/bug.php?id=36271

This is not a compatibility breaking change.



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