`

Error 1045 on sum function in pig latin with an int

    博客分类:
  • pig
 
阅读更多
--idc
A8 = load '/billing-log/idc/20140212.delay/' USING TextLoader() as (line:chararray);
B8 = FOREACH A8 GENERATE FLATTEN(IdcParser(line)) as (time:long,channel:chararray,user:chararray,billing:chararray,node:chararray,area:chararray,isp:chararray,in_traffic:long,out_traffic:long,in_bandwidth:long,out_bandwidth:long, max_bandwidth:long,dev_id:chararray,isup:chararray) ;

--报错
Bn = B8
Cn = filter Bn by (time is not null);
Un = filter Cn by (isup == '1');

--正常
Cn = filter B8 by (time is not null);
Un = filter Cn by (isup == '1');

不要创建没有意义的引用 Bn = B8


分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics