-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16829/#review31820
-----------------------------------------------------------



ql/src/java/org/apache/hadoop/hive/ql/optimizer/StatsOptimizer.java
<https://reviews.apache.org/r/16829/#comment60532>

    I think it is better (more readable) to move this condition to an inner if 
statement. Going to the else to check if it is count, just because it is not 
ExprNodeConstantDesc does not make sense.
    
    ie
    if(aggr.getParameters().get(0) instanceof ExprNodeConstantDesc){
    return null;
    }



ql/src/java/org/apache/hadoop/hive/ql/optimizer/StatsOptimizer.java
<https://reviews.apache.org/r/16829/#comment60533>

    can you also take care of this and other red marks ?
    



ql/src/java/org/apache/hadoop/hive/ql/optimizer/StatsOptimizer.java
<https://reviews.apache.org/r/16829/#comment60541>

    What about the case of sum(0.2). It looks like Long.parseLong() would not 
work with that.



ql/src/test/results/clientpositive/metadata_only_queries.q.out
<https://reviews.apache.org/r/16829/#comment60542>

    can you also add test with sum() with other supported (ie numeric) 
datatypes.


- Thejas Nair


On Jan. 13, 2014, 9:41 p.m., Ashutosh Chauhan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16829/
> -----------------------------------------------------------
> 
> (Updated Jan. 13, 2014, 9:41 p.m.)
> 
> 
> Review request for hive.
> 
> 
> Bugs: HIVE-6192
>     https://issues.apache.org/jira/browse/HIVE-6192
> 
> 
> Repository: hive-git
> 
> 
> Description
> -------
> 
> optimize sum(1) query so that it could be answered from metadata using stats
> 
> 
> Diffs
> -----
> 
>   ql/src/java/org/apache/hadoop/hive/ql/optimizer/StatsOptimizer.java 75390e7 
>   ql/src/test/queries/clientpositive/metadata_only_queries.q 7cbd148 
>   ql/src/test/results/clientpositive/metadata_only_queries.q.out b6d149a 
> 
> Diff: https://reviews.apache.org/r/16829/diff/
> 
> 
> Testing
> -------
> 
> Added test in metadata_only_queries.q which contains other similar tests.
> 
> 
> Thanks,
> 
> Ashutosh Chauhan
> 
>

Reply via email to