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

Iceberg integration: Implement merge into iceberg table

    XMLWordPrintableJSON

Details

    Description

      create external table target_ice(a int, b string, c int) partitioned by spec (bucket(16, a), truncate(3, b)) stored by iceberg stored as orc tblproperties ('format-version'='2');
      create table source(a int, b string, c int);
      
      ...
      
      merge into target_ice as t using source src ON t.a = src.a
      when matched and t.a > 100 THEN DELETE
      when matched then update set b = 'Merged', c = t.c + 10
      when not matched then insert values (src.a, src.b, src.c);
      
      

      Attachments

        Issue Links

          Activity

            People

              kkasa Krisztian Kasa
              kkasa Krisztian Kasa
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h 40m
                  1h 40m