t*u
2 楼
data3 = FOREACH data2 GENERATE group, SUM(data1.cpc) as cost:int;
data4 = ORDER data3 BY cost ASC;
如果
DESCRIBE data4;
不会报错
但是换成 DUMP data4;
就报错
2014-06-11 17:22:26,525 ERROR org.apache.pig.tools.pigstats.SimplePigStats:
ERROR: java.lang.RuntimeException: java.lang.ClassCastException: java.lang.L
ong cannot be cast to java.lang.Integer
2014-06-11 17:22:26,525 ERROR org.apache.pig.tools.pigstats.PigStatsUtil: 1
map reduce job(s) failed!
2014-06-11 17:22:26,573 ERROR org.apache.pig.tools.grunt.Grunt: ERROR 1066:
Unable to open iterator for alias data4. Backend error : java.lang.RuntimeEx
ception: java.lang.ClassCastException: java.lang.Long cannot be cast to java
.lang.Integer
data4: {group: chararray,cost: int}
里面没有出现需要long的地方啊
data4 = ORDER data3 BY cost ASC;
如果
DESCRIBE data4;
不会报错
但是换成 DUMP data4;
就报错
2014-06-11 17:22:26,525 ERROR org.apache.pig.tools.pigstats.SimplePigStats:
ERROR: java.lang.RuntimeException: java.lang.ClassCastException: java.lang.L
ong cannot be cast to java.lang.Integer
2014-06-11 17:22:26,525 ERROR org.apache.pig.tools.pigstats.PigStatsUtil: 1
map reduce job(s) failed!
2014-06-11 17:22:26,573 ERROR org.apache.pig.tools.grunt.Grunt: ERROR 1066:
Unable to open iterator for alias data4. Backend error : java.lang.RuntimeEx
ception: java.lang.ClassCastException: java.lang.Long cannot be cast to java
.lang.Integer
data4: {group: chararray,cost: int}
里面没有出现需要long的地方啊
k*o
3 楼
Before doing DUMP data4, mapreduce is not actually running.. "Describe"
works without mapreduce runs..
check the table for pig SUM :
http://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#SUM:
SUM returns long when input is int, but you assign it to cost: int..
This is where the runtime error comes from, I believe. change to "cost: long
", or simply "cost" without type specification..
.L
【在 t*********u 的大作中提到】
: data3 = FOREACH data2 GENERATE group, SUM(data1.cpc) as cost:int;
: data4 = ORDER data3 BY cost ASC;
: 如果
: DESCRIBE data4;
: 不会报错
: 但是换成 DUMP data4;
: 就报错
: 2014-06-11 17:22:26,525 ERROR org.apache.pig.tools.pigstats.SimplePigStats:
: ERROR: java.lang.RuntimeException: java.lang.ClassCastException: java.lang.L
: ong cannot be cast to java.lang.Integer
works without mapreduce runs..
check the table for pig SUM :
http://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#SUM:
SUM returns long when input is int, but you assign it to cost: int..
This is where the runtime error comes from, I believe. change to "cost: long
", or simply "cost" without type specification..
.L
【在 t*********u 的大作中提到】
: data3 = FOREACH data2 GENERATE group, SUM(data1.cpc) as cost:int;
: data4 = ORDER data3 BY cost ASC;
: 如果
: DESCRIBE data4;
: 不会报错
: 但是换成 DUMP data4;
: 就报错
: 2014-06-11 17:22:26,525 ERROR org.apache.pig.tools.pigstats.SimplePigStats:
: ERROR: java.lang.RuntimeException: java.lang.ClassCastException: java.lang.L
: ong cannot be cast to java.lang.Integer
t*u
4 楼
got it
thanks
long
【在 k****o 的大作中提到】
: Before doing DUMP data4, mapreduce is not actually running.. "Describe"
: works without mapreduce runs..
: check the table for pig SUM :
: http://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#SUM:
: SUM returns long when input is int, but you assign it to cost: int..
: This is where the runtime error comes from, I believe. change to "cost: long
: ", or simply "cost" without type specification..
:
: .L
thanks
long
【在 k****o 的大作中提到】
: Before doing DUMP data4, mapreduce is not actually running.. "Describe"
: works without mapreduce runs..
: check the table for pig SUM :
: http://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#SUM:
: SUM returns long when input is int, but you assign it to cost: int..
: This is where the runtime error comes from, I believe. change to "cost: long
: ", or simply "cost" without type specification..
:
: .L
t*u
5 楼
你的意思是 pig
相当于先编译成java
然后在执行?
long
【在 k****o 的大作中提到】
: Before doing DUMP data4, mapreduce is not actually running.. "Describe"
: works without mapreduce runs..
: check the table for pig SUM :
: http://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#SUM:
: SUM returns long when input is int, but you assign it to cost: int..
: This is where the runtime error comes from, I believe. change to "cost: long
: ", or simply "cost" without type specification..
:
: .L
相当于先编译成java
然后在执行?
long
【在 k****o 的大作中提到】
: Before doing DUMP data4, mapreduce is not actually running.. "Describe"
: works without mapreduce runs..
: check the table for pig SUM :
: http://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#SUM:
: SUM returns long when input is int, but you assign it to cost: int..
: This is where the runtime error comes from, I believe. change to "cost: long
: ", or simply "cost" without type specification..
:
: .L
相关阅读
有没有做sentiment analysis的,求思路 (转载)正在找data analyst/ scientist类的工作,人在纽约,open to relocate,希望各位朋友能推荐推荐San Jose Strata Conference Meet up (转载)请问如何完全跳到data scientist/analyst, 还有多大差距?征求大家意见,关于职业培训速成班data challenge ... 现在公司都咋tmd想的组里招DS,欢迎投条 (Valid Until 11/30/2017)请问这个怎么做?谢谢SAS coding help neededdata science微信出一个machine learning classification的题目转data science 要修个degree吗LinkedIn DA/ML SE 做哪方面的产品开发【专业分析】“数据科学”专业为什么在美国这么火?!Deep Learning in a Nutshell: Core Concepts统计杂志专刊征稿Insight Data Science Fellow Program 有人参加吗?有推荐的合适学校和专业吗? 多谢诚心求比较:<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="33604752475a40475a50407367727e66">[email protected]</a> vs <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="b4f5dad5d8cdc0ddd7c7f4f3d1dbc6d3ddd5">[email protected]</a> Tech像我这样的情况是应该坚持自学还是再读一个学位?