简体   繁体   English

猪过滤器命令不起作用

[英]Pig filter command is not work

I tried below in PIG but 4th command is not working. 我在下面的PIG中尝试过,但是第4条命令不起作用。

A = load '/user/mziauddi/logsam.txt' AS (str:chararray);
split1 = FOREACH A GENERATE FLATTEN(STRSPLIT(str, '\\,', 2)) AS (id:chararray, attr:chararray);
split2 = FOREACH split1 GENERATE id, STRSPLIT(attr, '[,]') AS attributes;
ORDER = FILTER split2 BY id=='ORD';

ORDER is a built-in command in Pig, you should not use as a relation name. ORDER是Pig中的内置命令,不应将其用作关系名称。 Can you change the relation name( ORDER ) to something different. 您可以将关系名称( ORDER )更改为其他名称吗?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM