使用hcatalog将数据从Pig模式加载到hive模式
我正在尝试以下查询以将数据从pig加载到蜂巢: data.txt 1,2.0,3.0,4.0使用hcatalog将数据从Pig模式加载到hive模式,hive,apache-pig,hadoop2,Hive,Apache Pig,Hadoop2,我正在尝试以下查询以将数据从pig加载到蜂巢: data.txt 1,2.0,3.0,4.0 r = load '/hdfs path/data.txt' using PigStorage(',') as (a:chararray,b:float,c:float,d:float); store r into 'db.table_name' using org.apache.hive.hcatalog.pig.HCatStorer(); 配置单元表的架构: (a串、b浮点数、c浮点数、d浮
r = load '/hdfs path/data.txt' using PigStorage(',') as (a:chararray,b:float,c:float,d:float);
store r into 'db.table_name' using org.apache.hive.hcatalog.pig.HCatStorer();
配置单元表的架构:
(a串、b浮点数、c浮点数、d浮点数)
上述清管器出现以下错误:
2016-07-01 08:43:35908[main]错误org.apache.pig.tools.pigstats.pigstats-错误0:java.lang.ClassCastException:org.apache.pig.data.DataByteArray无法转换为java.lang.Integer
2016-07-01 08:43:35909[main]错误strong textorg.apache.pig.tools.pigstats.mapreduce.MRPigStatsUtil-1个map reduce作业失败
以上在pig 0.15中对我有效,您使用的是哪个版本的pig?。另外,请对照pig版本的数据类型检查hive表的数据类型兼容性。以上内容在pig 0.15中对我有效,您使用的是哪个pig版本?。另外,请对照pig版本的数据类型检查配置单元表的数据类型兼容性。