Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-2742

InvalidOperationException "alter table is not possible" when using LOAD DATA INPATH OVERWRITE with database and partition

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 0.7.1
    • None
    • None
    • reproduced on cdh3u2 (haven't tried other versions)

    Description

      Here is a repeatable procedure:

      $ echo "test" | hadoop fs -put - test.txt
      $ echo "test2" | hadoop fs -put - test2.txt
      

      Then in hive:

      > create database catalog;
      > use catalog;
      > create table test_load (t string) partitioned by (p string);
      > use default;
      

      Then the problem arises:

      > load data inpath 'test.txt' overwrite into table catalog.test_load partition (p='test');
      Loading data to table catalog.test_load partition (p=test)
      OK
      Time taken: 0.175 seconds
      > load data inpath 'test2.txt' overwrite into table catalog.test_load partition (p='test');
      Loading data to table catalog.test_load partition (p=test)
      Moved to trash: hdfs://mycluster/user/hive/warehouse/catalog.db/test_load/p=test
      Failed with exception InvalidOperationException(message:alter is not possible)
      FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.MoveTask
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            brugidou Maxime Brugidou
            Votes:
            2 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated: