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

Optimize the column stats update logic in table alteration

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.3.0
    • Hive, Metastore
    • None

    Description

      Currently when a table is altered, if any of below conditions is true, HMS would try to update column statistics for the table:

      1. database name is changed
      2. table name is changed
      3. old columns and new columns are not the same

      As a result, when a column is added to a table, Hive also tries to update column statistics, which is not necessary. We can loose the last condition by checking whether all existing columns are changed or not. If not, we don't have to update stats info.

      Attachments

        1. HIVE-15530.1.patch
          3 kB
          Yibing Shi
        2. HIVE-15530.2.patch
          7 kB
          Yibing Shi
        3. HIVE-15530.3.patch
          8 kB
          Yibing Shi
        4. HIVE-15530.4.patch
          9 kB
          Yibing Shi
        5. HIVE-15530.5.patch
          11 kB
          Yibing Shi

        Activity

          People

            Yibing Yibing Shi
            Yibing Yibing Shi
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: