pig-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cheolsoo Park (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (PIG-3060) FLATTEN in nested foreach fails when the input contains an empty bag
Date Sun, 07 Apr 2013 21:35:15 GMT

    [ https://issues.apache.org/jira/browse/PIG-3060?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13625024#comment-13625024
] 

Cheolsoo Park commented on PIG-3060:
------------------------------------

+1.
                
> FLATTEN in nested foreach fails when the input contains an empty bag
> --------------------------------------------------------------------
>
>                 Key: PIG-3060
>                 URL: https://issues.apache.org/jira/browse/PIG-3060
>             Project: Pig
>          Issue Type: Bug
>          Components: impl
>    Affects Versions: 0.10.0
>            Reporter: Youngwook Kim
>            Assignee: Daniel Dai
>             Fix For: 0.12
>
>         Attachments: PIG-3060-1.patch
>
>
> FLATTEN inside a foreach statement produces wrong results, if the input contains an empty
bag.
> {code}
> A = load 'flatten.txt' as (a0:int, a1:bag{(t:chararray)});
> B = group A by a0;
> C = foreach B {
>   c1 = foreach A generate FLATTEN(a1);
>   generate COUNT(c1);
> };
> {code}
> The easy workaround is to filter out empty bags.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message