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

Transactions: Fix CTAS on Micromanaged tables

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0.0
    • 3.0.0
    • Transactions
    • None

    Description

      CTTAS on temporary micromanaged table does not write data. 

      I.e., "SELECT * FROM ctas0_mm;" does not return any rows from the below script:

       

      set hive.mapred.mode=nonstrict;

      set hive.explain.user=false;

      set hive.fetch.task.conversion=none;

      set tez.grouping.min-size=1;

      set tez.grouping.max-size=2;

      set hive.exec.dynamic.partition.mode=nonstrict;

      set hive.support.concurrency=true;

      set hive.txn.manager=org.apache.hadoop.hive.ql.lockmgr.DbTxnManager;

       

      drop table intermediate;

      create table intermediate(key int) partitioned by (p int) stored as orc;

      insert into table intermediate partition(p='455') select distinct key from src where key >= 0 order by key desc limit 2;

      insert into table intermediate partition(p='456') select distinct key from src where key is not null order by key asc limit 2;

      insert into table intermediate partition(p='457') select distinct key from src where key >= 100 order by key asc limit 2;

        

      drop table ctas0_mm; 

      explain create temporary table ctas0_mm tblproperties ("transactional"="true", "transactional_properties"="insert_only") as select * from intermediate;

      create temporary table ctas0_mm tblproperties ("transactional"="true", "transactional_properties"="insert_only") as select * from intermediate;

       

      select * from ctas0_mm;

      drop table ctas0_mm;

      drop table intermediate;

      Attachments

        1. HIVE-18599.04.patch
          8 kB
          Gopal Vijayaraghavan
        2. HIVE-18599.03.patch
          7 kB
          Steve Yeom
        3. HIVE-18599.02.patch
          2 kB
          Steve Yeom
        4. HIVE-18599.01.patch
          2 kB
          Steve Yeom

        Activity

          People

            steveyeom2017 Steve Yeom
            steveyeom2017 Steve Yeom
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: