hadoop-pig-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alan Gates (JIRA)" <j...@apache.org>
Subject [jira] Assigned: (PIG-900) ORDER BY syntax wrt parentheses is somewhat different than GROUP BY and FILTER BY
Date Mon, 13 Sep 2010 22:36:35 GMT

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

Alan Gates reassigned PIG-900:
------------------------------

    Assignee: Xuefu Zhang

> ORDER BY syntax wrt parentheses is somewhat different than GROUP BY and FILTER BY
> ---------------------------------------------------------------------------------
>
>                 Key: PIG-900
>                 URL: https://issues.apache.org/jira/browse/PIG-900
>             Project: Pig
>          Issue Type: Bug
>            Reporter: David Ciemiewicz
>            Assignee: Xuefu Zhang
>             Fix For: 0.9.0
>
>
> With GROUP BY, you must put parentheses around the aliases in the BY clause:
> {code}
> B = group A by ( a, b, c );
> {code}
> With FILTER BY, you can optionally put parentheses around the aliases in the BY clause:
> {code}
> B = filter A by ( a is not null and b is not null and c is not null );
> {code}
> However, with ORDER BY, if you put parenthesis around the BY clause, you get a syntax
error:
> {code}
>  A = order A by ( a, b, c );
> {code}
> Produces the error:
> {code}
> 2009-08-03 18:26:29,544 [main] ERROR org.apache.pig.tools.grunt.Grunt -
> ERROR 1000: Error during parsing. Encountered " "," ", "" at line 3, column 19.
> Was expecting:
>     ")" ...
> {code}
> This is an annoyance really.
> Here's my full code example ...
> {code}
> A = load 'data.txt' using PigStorage as (a: chararray, b: chararray, c: chararray );
> A = order A by ( a, b, c );
> dump A;
> {code}

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


Mime
View raw message