pig-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nick White (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (PIG-1708) Cross after Limit produces wrong results
Date Sat, 27 Jul 2013 03:09:50 GMT

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

Nick White updated PIG-1708:
----------------------------

    Attachment: Test1708.java

I've attached a JUnit test with the code in this ticket, but it passes?
                
> Cross after Limit produces wrong results
> ----------------------------------------
>
>                 Key: PIG-1708
>                 URL: https://issues.apache.org/jira/browse/PIG-1708
>             Project: Pig
>          Issue Type: Bug
>    Affects Versions: 0.7.0
>            Reporter: Anil Chawla
>         Attachments: Test1708.java
>
>
> It seems that the CROSS operation is producing empty or missing results when it involves
a LIMITed alias. For example, this script loads some data and appends the record count to
each row. The LIMIT in this case is unnecessary but is used to demonstrate the issue:
> a = load 'bug.txt' using PigStorage(',') as (word1, word2);
> b = group a all;
> c = foreach b generate COUNT(a) as count;
> limit_c = LIMIT c 1;
> d = cross a, limit_c;
> dump d;
> This produces empty results with my simple test data of 4 rows. However, changing it
to "d = cross a, c" produces the correct results. This does not make sense because "c" and
"limit_c"  have the same value.

--
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