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

George Mavromatis updated PIG-812:
----------------------------------


First, I have to say that the updated documentation specifies adequately 
further undocumented but important details of pig syntax and behavior (e.g. 
dereference) in addition to the ones mentioned in this ticket. Very good job! 
This will improve usability of pig significantly. Thank you.

Regarding the particular points in this ticket:

1) Description is adequate for pig. Contrast with sql is nice to have, not 
crucial.
2) These parts were probably edited by Corinne. Examples may help, but again 
the spec is important to have and that was addressed.
3) 'key' or key should be consistent in both "symbol" and "notes" sections.
4) I think the parenthesis pair is correct. This specification of flatten is 
quite clear!
5) No opinion.


> COUNT(*) does not work 
> -----------------------
>
>                 Key: PIG-812
>                 URL: https://issues.apache.org/jira/browse/PIG-812
>             Project: Pig
>          Issue Type: Bug
>          Components: impl
>    Affects Versions: 0.2.0
>            Reporter: Viraj Bhat
>            Assignee: Benjamin Reed
>             Fix For: 0.2.0
>
>         Attachments: PIG-812.patch, PIG-812.patch, PIG-812.pdf, studenttab10k
>
>
> Pig script to count the number of rows in a studenttab10k file which contains 
> 10k records.
> {code}
> studenttab = LOAD 'studenttab10k' AS (name:chararray, age:int,gpa:float);
> X2 = GROUP studenttab ALL;
> describe X2;
> Y2 = FOREACH X2 GENERATE COUNT(*);
> explain Y2;
> DUMP Y2;
> {code}
> returns the following error
> ================================================================
> ERROR org.apache.pig.tools.grunt.Grunt - ERROR 1066: Unable to open iterator 
> for alias Y2
> Details at logfile: /homes/viraj/pig-svn/trunk/pig_1242783700970.log
> ================================================================
> If you look at the log file:
> ================================================================
> Caused by: java.lang.ClassCastException
>         at org.apache.pig.builtin.COUNT$Initial.exec(COUNT.java:76)
>         at org.apache.pig.builtin.COUNT$Initial.exec(COUNT.java:68)
>         at 
> org.apache.pig.backend.hadoop.executionengine.physicalLayer.expressionOperators.POUserFunc.getNext(POUserFunc.java:201)
>         at 
> org.apache.pig.backend.hadoop.executionengine.physicalLayer.expressionOperators.POUserFunc.getNext(POUserFunc.java:235)
>         at 
> org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.POForEach.processPlan(POForEach.java:254)
>         at 
> org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.POForEach.getNext(POForEach.java:204)
>         at 
> org.apache.pig.backend.hadoop.executionengine.physicalLayer.PhysicalOperator.processInput(PhysicalOperator.java:231)
>         at 
> org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.POLocalRearrange.getNext(POLocalRearrange.java:223)
>         at 
> org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.PigMapBase.runPipeline(PigMapBase.java:245)
>         at 
> org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.PigMapBase.map(PigMapBase.java:236)
>         at 
> org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.PigMapReduce$Map.map(PigMapReduce.java:88)
>         at org.apache.hadoop.mapred.MapRunner.run(MapRunner.java:47)
>         at org.apache.hadoop.mapred.MapTask.run(MapTask.java:227)
> ================================================================

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

Reply via email to