FAQ
Limit produces results in the wrong order
-----------------------------------------

Key: PIG-461
URL: https://issues.apache.org/jira/browse/PIG-461
Project: Pig
Issue Type: Bug
Reporter: Olga Natkovich
Assignee: Alan Gates


Script:

A = load 'studenttab200m' as (name, age, gpa);
B = filter A by age > 20;
C = group B by name;
D = foreach C generate group, COUNT(B) PARALLEL 16;
E = order D by $0 PARALLEL 16;
F = limit E 10;
--explain F;
dump F;

Output:

comes out not sorted on the name

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Search Discussions

  • Olga Natkovich (JIRA) at Sep 25, 2008 at 7:04 pm
    [ https://issues.apache.org/jira/browse/PIG-461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

    Olga Natkovich updated PIG-461:
    -------------------------------

    Fix Version/s: types_branch
    Affects Version/s: types_branch
    Limit produces results in the wrong order
    -----------------------------------------

    Key: PIG-461
    URL: https://issues.apache.org/jira/browse/PIG-461
    Project: Pig
    Issue Type: Bug
    Affects Versions: types_branch
    Reporter: Olga Natkovich
    Assignee: Alan Gates
    Fix For: types_branch


    Script:
    A = load 'studenttab200m' as (name, age, gpa);
    B = filter A by age > 20;
    C = group B by name;
    D = foreach C generate group, COUNT(B) PARALLEL 16;
    E = order D by $0 PARALLEL 16;
    F = limit E 10;
    --explain F;
    dump F;
    Output:
    comes out not sorted on the name
    --
    This message is automatically generated by JIRA.
    -
    You can reply to this email to add a comment to the issue online.
  • Alan Gates (JIRA) at Sep 26, 2008 at 12:54 am
    [ https://issues.apache.org/jira/browse/PIG-461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

    Alan Gates updated PIG-461:
    ---------------------------

    Attachment: PIG-461.patch

    Fixed MRCompiler and JobControlCompiler so that limit that is added to the end to get a single reduce will use the same sort partitioner as the order by above it.
    Limit produces results in the wrong order
    -----------------------------------------

    Key: PIG-461
    URL: https://issues.apache.org/jira/browse/PIG-461
    Project: Pig
    Issue Type: Bug
    Affects Versions: types_branch
    Reporter: Olga Natkovich
    Assignee: Alan Gates
    Fix For: types_branch

    Attachments: PIG-461.patch


    Script:
    A = load 'studenttab200m' as (name, age, gpa);
    B = filter A by age > 20;
    C = group B by name;
    D = foreach C generate group, COUNT(B) PARALLEL 16;
    E = order D by $0 PARALLEL 16;
    F = limit E 10;
    --explain F;
    dump F;
    Output:
    comes out not sorted on the name
    --
    This message is automatically generated by JIRA.
    -
    You can reply to this email to add a comment to the issue online.
  • Alan Gates (JIRA) at Sep 26, 2008 at 12:54 am
    [ https://issues.apache.org/jira/browse/PIG-461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

    Alan Gates updated PIG-461:
    ---------------------------

    Status: Patch Available (was: Open)
    Limit produces results in the wrong order
    -----------------------------------------

    Key: PIG-461
    URL: https://issues.apache.org/jira/browse/PIG-461
    Project: Pig
    Issue Type: Bug
    Affects Versions: types_branch
    Reporter: Olga Natkovich
    Assignee: Alan Gates
    Fix For: types_branch

    Attachments: PIG-461.patch


    Script:
    A = load 'studenttab200m' as (name, age, gpa);
    B = filter A by age > 20;
    C = group B by name;
    D = foreach C generate group, COUNT(B) PARALLEL 16;
    E = order D by $0 PARALLEL 16;
    F = limit E 10;
    --explain F;
    dump F;
    Output:
    comes out not sorted on the name
    --
    This message is automatically generated by JIRA.
    -
    You can reply to this email to add a comment to the issue online.
  • Olga Natkovich (JIRA) at Sep 26, 2008 at 4:16 am
    [ https://issues.apache.org/jira/browse/PIG-461?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12634743#action_12634743 ]

    Olga Natkovich commented on PIG-461:
    ------------------------------------

    +1
    Limit produces results in the wrong order
    -----------------------------------------

    Key: PIG-461
    URL: https://issues.apache.org/jira/browse/PIG-461
    Project: Pig
    Issue Type: Bug
    Affects Versions: types_branch
    Reporter: Olga Natkovich
    Assignee: Alan Gates
    Fix For: types_branch

    Attachments: PIG-461.patch


    Script:
    A = load 'studenttab200m' as (name, age, gpa);
    B = filter A by age > 20;
    C = group B by name;
    D = foreach C generate group, COUNT(B) PARALLEL 16;
    E = order D by $0 PARALLEL 16;
    F = limit E 10;
    --explain F;
    dump F;
    Output:
    comes out not sorted on the name
    --
    This message is automatically generated by JIRA.
    -
    You can reply to this email to add a comment to the issue online.
  • Daniel Dai (JIRA) at Sep 26, 2008 at 6:56 am
    [ https://issues.apache.org/jira/browse/PIG-461?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12634770#action_12634770 ]

    Daniel Dai commented on PIG-461:
    --------------------------------

    Looks good to me, thanks Alan
    Limit produces results in the wrong order
    -----------------------------------------

    Key: PIG-461
    URL: https://issues.apache.org/jira/browse/PIG-461
    Project: Pig
    Issue Type: Bug
    Affects Versions: types_branch
    Reporter: Olga Natkovich
    Assignee: Alan Gates
    Fix For: types_branch

    Attachments: PIG-461.patch


    Script:
    A = load 'studenttab200m' as (name, age, gpa);
    B = filter A by age > 20;
    C = group B by name;
    D = foreach C generate group, COUNT(B) PARALLEL 16;
    E = order D by $0 PARALLEL 16;
    F = limit E 10;
    --explain F;
    dump F;
    Output:
    comes out not sorted on the name
    --
    This message is automatically generated by JIRA.
    -
    You can reply to this email to add a comment to the issue online.
  • Alan Gates (JIRA) at Sep 26, 2008 at 3:46 pm
    [ https://issues.apache.org/jira/browse/PIG-461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

    Alan Gates updated PIG-461:
    ---------------------------

    Resolution: Fixed
    Status: Resolved (was: Patch Available)

    Patch checked in.
    Limit produces results in the wrong order
    -----------------------------------------

    Key: PIG-461
    URL: https://issues.apache.org/jira/browse/PIG-461
    Project: Pig
    Issue Type: Bug
    Affects Versions: types_branch
    Reporter: Olga Natkovich
    Assignee: Alan Gates
    Fix For: types_branch

    Attachments: PIG-461.patch


    Script:
    A = load 'studenttab200m' as (name, age, gpa);
    B = filter A by age > 20;
    C = group B by name;
    D = foreach C generate group, COUNT(B) PARALLEL 16;
    E = order D by $0 PARALLEL 16;
    F = limit E 10;
    --explain F;
    dump F;
    Output:
    comes out not sorted on the name
    --
    This message is automatically generated by JIRA.
    -
    You can reply to this email to add a comment to the issue online.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupdev @
categoriespig, hadoop
postedSep 25, '08 at 7:02p
activeSep 26, '08 at 3:46p
posts7
users1
websitepig.apache.org

1 user in discussion

Alan Gates (JIRA): 7 posts

People

Translate

site design / logo © 2022 Grokbase