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

Union with partition tables which have no data fails with NPE

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.2.0
    • 1.2.0
    • Tez
    • None

    Description

      As shown in the test case in the patch below, when we have partitioned tables which have no data, we fail with an NPE with the following stack trace:

      NullPointerException null
      java.lang.NullPointerException
        at org.apache.hadoop.hive.ql.lib.DefaultGraphWalker.walk(DefaultGraphWalker.java:128)
        at org.apache.hadoop.hive.ql.lib.DefaultGraphWalker.startWalking(DefaultGraphWalker.java:109)
        at org.apache.hadoop.hive.ql.optimizer.physical.Vectorizer$VectorizationDispatcher.validateMapWork(Vectorizer.java:357)
        at org.apache.hadoop.hive.ql.optimizer.physical.Vectorizer$VectorizationDispatcher.convertMapWork(Vectorizer.java:321)
        at org.apache.hadoop.hive.ql.optimizer.physical.Vectorizer$VectorizationDispatcher.dispatch(Vectorizer.java:307)
        at org.apache.hadoop.hive.ql.lib.TaskGraphWalker.dispatch(TaskGraphWalker.java:111)
        at org.apache.hadoop.hive.ql.lib.TaskGraphWalker.walk(TaskGraphWalker.java:194)
        at org.apache.hadoop.hive.ql.lib.TaskGraphWalker.startWalking(TaskGraphWalker.java:139)
        at org.apache.hadoop.hive.ql.optimizer.physical.Vectorizer.resolve(Vectorizer.java:847)
        at org.apache.hadoop.hive.ql.parse.TezCompiler.optimizeTaskPlan(TezCompiler.java:468)
        at org.apache.hadoop.hive.ql.parse.TaskCompiler.compile(TaskCompiler.java:223)
        at org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.analyzeInternal(SemanticAnalyzer.java:10170)
        at org.apache.hadoop.hive.ql.parse.BaseSemanticAnalyzer.analyze(BaseSemanticAnalyzer.java:221)
        at org.apache.hadoop.hive.ql.parse.ExplainSemanticAnalyzer.analyzeInternal(ExplainSemanticAnalyzer.java:74)
        at org.apache.hadoop.hive.ql.parse.BaseSemanticAnalyzer.analyze(BaseSemanticAnalyzer.java:221)
      

      Attachments

        1. HIVE-10273.1.0.patch
          125 kB
          Vikram Dixit K
        2. HIVE-10273.6.patch
          175 kB
          Vikram Dixit K
        3. HIVE-10273.5.patch
          173 kB
          Vikram Dixit K
        4. HIVE-10273.4.patch
          143 kB
          Vikram Dixit K
        5. HIVE-10273.3.patch
          21 kB
          Vikram Dixit K
        6. HIVE-10273.2.patch
          7 kB
          Vikram Dixit K
        7. HIVE-10273.1.patch
          7 kB
          Vikram Dixit K

        Activity

          People

            vikram.dixit Vikram Dixit K
            vikram.dixit Vikram Dixit K
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: