【发布时间】:2014-08-24 23:45:28
【问题描述】:
我在创建 hive 表时遇到以下异常。谁能指出我的错误? 示例输入:{"user":{"userlocation":"Bolton, UK","id":14141159,"name":"Chris Beckett","screenname":"ChrisBeckett","geoenabled":true}," tweetmessage":"vCOps 人 - 高级版 == 5 个 VM?我知道 Std 有 UI 和分析 VM,但其余的使用什么?Hyperic 等?#vmware #vcops","createddate":"2013-06-20T12: 08:46","地理位置":null}
enter code here
CREATE EXTERNAL TABLE IF NOT EXISTS twitter(
users map<string,string,string,string,string>,
message string,
createddate string,
geolocation string
)
ROW FORMAT SERDE 'org.apache.hadoop.hive.contrib.serde2.JsonSerde'
LOCATION ' /user/root/hadoop_tests/sample_twitter_data.txt';
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.util.RunJar.main(RunJar.java:212)
FAILED: ParseException line 2:23 missing > at ',' near 'string' in column type 第 2:30 行无法识别列类型中 ',' 'string' ',' 附近的输入
【问题讨论】: