hadoop-hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Namit Jain (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HIVE-1116) bug with alter table rename when table has property EXTERNAL=FALSE
Date Wed, 12 May 2010 18:10:46 GMT

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

Namit Jain commented on HIVE-1116:
----------------------------------

+1



> bug with alter table rename when table has property EXTERNAL=FALSE
> ------------------------------------------------------------------
>
>                 Key: HIVE-1116
>                 URL: https://issues.apache.org/jira/browse/HIVE-1116
>             Project: Hadoop Hive
>          Issue Type: Bug
>    Affects Versions: 0.5.0
>            Reporter: Joydeep Sen Sarma
>            Assignee: John Sichi
>             Fix For: 0.6.0
>
>         Attachments: HIVE-1116.1.patch
>
>
> if the location is not an external location - this would be safer.
> the problem right now is that it's tricky to use the drop and rename way of writing new
data into a table. consider:
> Initialization block:
> drop table a_tmp
> create table a_tmp like a;
> Loading block:
> load data <newdata> into a_tmp;
> drop table a;
> alter table a_tmp rename to a;
> this looks safe. but it's not. if one runs this multiple times - then data is lost (since
'a' is pointing to 'a_tmp''s location after any iteration. and dropping table 'a' blows away
loaded data in the next iteration). 
> if the location is being managed by Hive - then 'rename' should switch location as well.

-- 
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