查询未在Hive中执行

时间:2018-03-25 08:51:50

标签: hadoop hive

hive> create table daily_revenue as
select order_date, sum(order_item_subtotal) daily_revenue
from orders join order_items on
order_id = order_item_order_id
group by order_date;

运行上述查询后,我无法按预期获得输出。

  

输出>查询ID = cloudera_20180323115454_7aff9398-59bd-4492-82e6-fa065251134e       总工作量= 2       FAILED:执行错误,从org.apache.hadoop.hive.ql.exec.mr.MapredLocalTask​​返回代码1

     

ErrorInformation>   将table daily_revenue创建为   选择order_date,sum(order_item_subtotal)daily_revenue   从订单加入order_items   order_id = order_item_order_id   order_date喜欢' 2013-07%'   按order_date分组   2018-03-25 18:47:45,642 INFO [main]:ql.Driver(Driver.java:compile(570)) - 语义分析完成   2018-03-25 18:47:45,642 INFO [main]:ql.Driver(Driver.java:getSchema(303)) - 返回Hive架构:架构(fieldSchemas:[FieldSchema(名称:order_date,类型:字符串,注释: null),FieldSchema(name:daily_revenue,type:double,comment:null)],properties:null)   2018-03-25 18:47:45,643 INFO [main]:ql.Driver(Driver.java:compile(690)) - 完成编译命令(queryId = cloudera_20180325184747_8e5480aa-b46d-41f4-8bea-6f2f4ffd737d);所用时间:0.304秒   2018-03-25 18:47:45,643 INFO [main]:ql.Driver(Driver.java:checkConcurrency(223)) - 并发模式被禁用,没有创建锁管理器   2018-03-25 18:47:45,643 INFO [main]:ql.Driver(Driver.java:execute(1656)) - 执行命令(queryId = cloudera_20180325184747_8e5480aa-b46d-41f4-8bea-6f2f4ffd737d):创建table daily_revenue as   选择order_date,sum(order_item_subtotal)daily_revenue   从订单加入order_items   order_id = order_item_order_id   order_date喜欢' 2013-07%'   按order_date分组   2018-03-25 18:47:45,643 INFO [main]:ql.Driver(SessionState.java:printInfo(1080)) - 查询ID = cloudera_20180325184747_8e5480aa-b46d-41f4-8bea-6f2f4ffd737d   2018-03-25 18:47:45,643 INFO [main]:ql.Driver(SessionState.java:printInfo(1080)))--总工作数= 1   2018-03-25 18:47:45,658 INFO [main]:ql.Driver(Driver.java:launchTask(2039)) - 以串行模式启动任务[Stage-6:MAPREDLOCAL]   2018-03-25 18:47:45,661 INFO [main]:mr.MapredLocalTask​​(MapredLocalTask​​.java:executeInChildVM(172)) - 生成计划文件文件:/ tmp / cloudera / 637b88e2-3c64-454d-b15a-eb95f3a501dd / hive_2018 -03-25_18-47-45_338_6357453693718710628-1 / -local-10006 / plan.xml中   2018-03-25 18:47:46,296 INFO [main]:mr.MapredLocalTask​​(MapredLocalTask​​.java:executeInChildVM(319)) - 执行:/ usr / lib / hadoop / bin / hadoop jar / usr / lib / hive / lib /hive-exec-1.1.0-cdh5.12.0.jar org.apache.hadoop.hive.ql.exec.mr.ExecDriver -localtask -plan file:/ tmp / cloudera / 637b88e2-3c64-454d-b15a-eb95f3a501dd / hive_2018-03-25_18-47-45_338_6357453693718710628-1 / -local-10006 / plan.xml -jobconffile file:/ tmp / cloudera / 637b88e2-3c64-454d-b15a-eb95f3a501dd / hive_2018-03-25_18-47-45_338_6357453693718710628-1 /-local-10007/jobconf.xml   2018-03-25 18:47:46,309 ERROR [main]:mr.MapredLocalTask​​(MapredLocalTask​​.java:executeInChildVM(351)) - 例外:   显示java.lang.NullPointerException       at org.apache.hadoop.hive.ql.exec.mr.MapredLocalTask​​.executeInChildVM(MapredLocalTask​​.java:326)       在org.apache.hadoop.hive.ql.exec.mr.MapredLocalTask​​.execute(MapredLocalTask​​.java:153)       在org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:214)       在org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:99)       在org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:2041)       在org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1748)       在org.apache.hadoop.hive.ql.Driver.runInternal(Driver.java:1501)       在org.apache.hadoop.hive.ql.Driver.run(Driver.java:1285)       在org.apache.hadoop.hive.ql.Driver.run(Driver.java:1275)       在org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:220)       在org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:172)       在org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:383)       在org.apache.hadoop.hive.cli.CliDriver.executeDriver(CliDriver.java:775)       在org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:693)       在org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:628)       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)       at java.lang.reflect.Method.invoke(Method.java:606)       在org.apache.hadoop.util.RunJar.run(RunJar.java:221)       在org.apache.hadoop.util.RunJar.main(RunJar.java:136)   2018-03-25 18:47:46,310 ERROR [main]:ql.Driver(SessionState.java:printError(1103)) - FAILED:执行错误,从org.apache.hadoop.hive.ql.exec返回代码1。 mr.MapredLocalTask   2018-03-25 18:47:46,312 INFO [main]:ql.Driver(Driver.java:execute(1947)) - 完成执行命令(queryId = cloudera_20180325184747_8e5480aa-b46d-41f4-8bea-6f2f4ffd737d);所用时间:0.669秒

0 个答案:

没有答案