You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pig.apache.org by "Daniel Dai (JIRA)" <ji...@apache.org> on 2011/02/19 00:59:38 UTC
[jira] Resolved: (PIG-1860) Bug in plan built for Nested foreach
[ https://issues.apache.org/jira/browse/PIG-1860?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Daniel Dai resolved PIG-1860.
-----------------------------
Resolution: Duplicate
The issue share the same problem with PIG-1858. Mark it as duplicate and move discussion to PIG-1858.
> Bug in plan built for Nested foreach
> -------------------------------------
>
> Key: PIG-1860
> URL: https://issues.apache.org/jira/browse/PIG-1860
> Project: Pig
> Issue Type: Bug
> Affects Versions: 0.8.0, 0.9.0
> Reporter: Vivek Padmanabhan
>
> Using the same inputs as in PIG-1858,
> {code}
> register myanotherudf.jar;
> A = load 'myinput' using PigStorage() as ( date:chararray,bcookie:chararray,count:int,avg:double,pvs:int);
> B = foreach A generate (int)(avg / 100.0) * 100 as avg, pvs;
> C = group B by ( avg );
> D = foreach C {
> Pvs = order B by pvs;
> Const = org.vivek.MyAnotherUDF(Pvs.pvs).(count,sum);
> generate Const.sum as sum;
> };
> store D into 'out_D';
> {code}
> In this script even though I am passing Pvs.pvs to the UDF in the nested foreach, at runtime the "avg" is getting passed.
> It looks like the logical plan created for D is wrong.
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira