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

Row sampling throws NPE when used in sub-query

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.12.0
    • Component/s: Query Processor
    • Labels:
      None

      Description

      select * from (select * from src TABLESAMPLE (1 ROWS)) x;

      ava.lang.NullPointerException
      	at org.apache.hadoop.hive.ql.parse.SplitSample.getTargetSize(SplitSample.java:103)
      	at org.apache.hadoop.hive.ql.io.CombineHiveInputFormat.sampleSplits(CombineHiveInputFormat.java:487)
      	at org.apache.hadoop.hive.ql.io.CombineHiveInputFormat.getSplits(CombineHiveInputFormat.java:405)
      	at org.apache.hadoop.mapred.JobClient.writeOldSplits(JobClient.java:1025)
      	at org.apache.hadoop.mapred.JobClient.writeSplits(JobClient.java:1017)
      	at org.apache.hadoop.mapred.JobClient.access$600(JobClient.java:174)
      	at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:928)
      	at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:881)
      	at java.security.AccessController.doPrivileged(Native Method)
      	at javax.security.auth.Subject.doAs(Subject.java:396)
      	at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1278)
      	at org.apache.hadoop.mapred.JobClient.submitJobInternal(JobClient.java:881)
      	at org.apache.hadoop.mapred.JobClient.submitJob(JobClient.java:855)
      	at org.apache.hadoop.hive.ql.exec.mr.ExecDriver.execute(ExecDriver.java:426)
      	at org.apache.hadoop.hive.ql.exec.mr.MapRedTask.execute(MapRedTask.java:144)
      	at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:151)
      	at org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:65)
      	at org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:1424)
      	at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1204)
      	at org.apache.hadoop.hive.ql.Driver.runInternal(Driver.java:1009)
      	at org.apache.hadoop.hive.ql.Driver.run(Driver.java:878)
      	at org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:259)
      	at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:216)
      	at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:413)
      	at org.apache.hadoop.hive.cli.CliDriver.executeDriver(CliDriver.java:781)
      	at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:675)
      	at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:614)
      

        Attachments

        1. HIVE-5061.D12165.1.patch
          4 kB
          Phabricator

          Activity

            People

            • Assignee:
              navis Navis Ryu
              Reporter:
              navis Navis Ryu
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: