hive 報錯 Caused by: java.lang.reflect.InvocationTargetException
阿新 • • 發佈:2019-02-13
向一個表的分割槽中插入資料時
報錯
java.lang.RuntimeException: Error in configuring object at org.apache.hadoop.util.ReflectionUtils.setJobConf(ReflectionUtils.java:106) at org.apache.hadoop.util.ReflectionUtils.setConf(ReflectionUtils.java:72) at org.apache.hadoop.util.ReflectionUtils.newInstance(ReflectionUtils.java:130) at org.apache.hadoop.mapred.ReduceTask.runOldReducer(ReduceTask.java:469) at org.apache.hadoop.mapred.ReduceTask.run(ReduceTask.java:447) at org.apache.hadoop.mapred.Child$4.run(Child.java:268) 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:1408) at org.apache.hadoop.mapred.Child.main(Child.java:262) Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAc
sql語句如下
insert into table test_mid_pro_androidupdate partition(year='2013',month='09',day='29') select 20130929, a.uid, a.vid, cityid, channelid, 1 from ( select case when vid=1301 then 1237 when vid=1162 then 1154 else vid end as vid , uid, case when collect_set(cityid)[0] is not null then collect_set(cityid)[0] else 0 end as cityid, collect_set(channelid)[0] channelid from (select cast(vid as int) vid, uid, cast(cityid as int) cityid, channelid, year, month, day from pwd_act_user) c where year=2013 and month=09 and day=29 and vid in (1162, 1154, 1237, 1301) group by uid, vid ) a left outer join ( select id from pwd_user_info where crttime like '2013-09-29%' ) b on (a.uid=b.id) where b.id is null;
單獨執行 後面的select的語句沒有出錯,但是 加上第一句insert into 當map跑完後 跑reduce時就報錯