pig-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dmitriy V. Ryaboy (Resolved) (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (PIG-2365) Current TOP implementation needlessly results in a null bag name
Date Tue, 15 Nov 2011 05:01:52 GMT

     [ https://issues.apache.org/jira/browse/PIG-2365?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Dmitriy V. Ryaboy resolved PIG-2365.
------------------------------------

    Resolution: Fixed
    
> Current TOP implementation needlessly results in a null bag name
> ----------------------------------------------------------------
>
>                 Key: PIG-2365
>                 URL: https://issues.apache.org/jira/browse/PIG-2365
>             Project: Pig
>          Issue Type: Improvement
>    Affects Versions: 0.9.1, 0.10
>            Reporter: Jonathan Coveney
>            Assignee: Jonathan Coveney
>            Priority: Minor
>             Fix For: 0.11
>
>         Attachments: top.patch
>
>
> Given that TOP is basically always used with FLATTEN, now that FLATTEN prepends the bag
name, the output is suboptimal.
> a = load 'thing' as (x:int, y:int, z:int);
> b = group a all;
> c = foreach b generate flatten(TOP(10,1,a));
> describe c;
> --currently: c: {null::x: int,null::y: int,null::z: int}
> --without a one line change could be: c: {a::x: int,a::y: int,a::z: int}
> The current implementation actually throws away this info, so it's just a matter of not
doing that. Patch attached.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message