You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pig.apache.org by "Pradeep Kamath (JIRA)" <ji...@apache.org> on 2008/05/30 19:28:45 UTC
[jira] Issue Comment Edited: (PIG-248) Pig Local give wrong results
[ https://issues.apache.org/jira/browse/PIG-248?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12601202#action_12601202 ]
pkamath edited comment on PIG-248 at 5/30/08 10:28 AM:
--------------------------------------------------------------
With a flatten in the generate, correct results are obtained:
cat ~/work/pig/localtest.pig
a = load '/homes/pradeepk/work/pig/localtest.txt' as (c1, c2, c3);
b = group a by c1;
c = foreach b { d = order a by c3; generate flatten(d); }
dump c;
(abc, http://www.sss.net, a)
(abc, http://www.rrr.com, b)
(def, http://local.yahoo.com/, d)
(def, http://lmn.com/, f)
(def, http://xyz.com/, g)
Could be an issue with dump in local mode?
The types implementation for the next release of PIG has changes in the local mode code - this bug should also be addressed in that re-write
was (Author: pkamath):
With a flatten in the generate, correct results are obtained:
cat ~/work/pig/localtest.pig
a = load '/homes/pradeepk/work/pig/localtest.txt' as (c1, c2, c3);
b = group a by c1;
c = foreach b { d = order a by c3; generate flatten(d); }
dump c;
[pradeepk@afterside:~/dev/pig-yahoo/pig/test/nightly/perl]
(abc, http://www.sss.net, a)
(abc, http://www.rrr.com, b)
(def, http://local.yahoo.com/, d)
(def, http://lmn.com/, f)
(def, http://xyz.com/, g)
Could be an issue with dump in local mode?
The types implementation for the next release of PIG has changes in the local mode code - this bug should also be addressed in that re-write
> Pig Local give wrong results
> ----------------------------
>
> Key: PIG-248
> URL: https://issues.apache.org/jira/browse/PIG-248
> Project: Pig
> Issue Type: Bug
> Environment: Pig Local
> Reporter: Amir Youssefi
> Assignee: Pradeep Kamath
>
> Pig Local mode gives wrong results (but Pig + Hadoop give correct results) . This created issues for users who tried to debug in local mode...
> Here's my pig code:
> a = load '/homes/amiry/tmp/my_test.txt' as (c1,c2,c3);
> b = group a by c1;
> c = foreach b {
> d = order a by c3;
> generate d;
> }
> dump c;
> Pig + Hadoop:
> ({(abc, http://www.sss.net, a), (abc, http://www.rrr.com, b)})
> ({(def, http://local.yahoo.com/, d), (def, http://lmn.com/, f), (def, http://xyz.com/, g)})
> Pig Local:
> ({(abc, http://www.sss.net, a), (abc, http://www.rrr.com, b)})
> ({})
> Input:
> abc http://www.rrr.com b
> abc http://www.sss.net a
> def http://local.yahoo.com/ d
> def http://lmn.com/ f
> def http://xyz.com/ g
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.