hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ashutosh Chauhan <hashut...@apache.org>
Subject Re: Review Request 57094: HIVE-15996
Date Thu, 02 Mar 2017 01:43:18 GMT

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




ql/src/test/results/clientpositive/groupby_grouping_sets_grouping.q.out
Line 436 (original), 436 (patched)
<https://reviews.apache.org/r/57094/#comment239552>

    Not sure if standard says anything, but sql server has return type of tinyint for grouping:
https://msdn.microsoft.com/en-us/library/ms178544.aspx



ql/src/test/results/clientpositive/groupby_grouping_sets_grouping.q.out
Lines 1070 (patched)
<https://reviews.apache.org/r/57094/#comment239550>

    This looks incorrect. When both columns are NULL NULL meaning all rows are present in
this group grouping(k) = 1 and grouping(value)=1 and grouping(key,value) = 3. Instead we are
getting 0.
    Verified on oracle as well.



ql/src/test/results/clientpositive/groupby_grouping_sets_grouping.q.out
Lines 1071 (patched)
<https://reviews.apache.org/r/57094/#comment239551>

    select k, value, grouping(k), grouping(value), grouping_id(k,value)
    from T1
    group by cube(k, value);
    
    Output:
    K	VALUE	GROUPING(K)	GROUPING(VALUE)	GROUPING_ID(K,VALUE)
     - 	 - 	1	0	2
     - 	 - 	1	1	3
     - 	1	1	0	2
     - 	2	1	0	2
     - 	3	1	0	2
     - 	5	1	0	2
    1	 - 	0	0	0
    1	 - 	0	1	1
    1	1	0	0	0
    2	 - 	0	1	1
    2	2	0	0	0
    3	 - 	0	0	0
    3	 - 	0	1	1
    3	3	0	0	0
    4	 - 	0	1	1
    4	5	0	0	0


- Ashutosh Chauhan


On Feb. 27, 2017, 2:37 p.m., Jesús Camacho Rodríguez wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/57094/
> -----------------------------------------------------------
> 
> (Updated Feb. 27, 2017, 2:37 p.m.)
> 
> 
> Review request for hive and Ashutosh Chauhan.
> 
> 
> Bugs: HIVE-15996
>     https://issues.apache.org/jira/browse/HIVE-15996
> 
> 
> Repository: hive-git
> 
> 
> Description
> -------
> 
> HIVE-15996
> 
> 
> Diffs
> -----
> 
>   ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java 0872e535a9b6a09569c02fc498dab16867ca8783

>   ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDFGrouping.java cc015268de0ab1e32401c1cf7c21502fb2a45331

>   ql/src/test/queries/clientpositive/groupby_grouping_sets_grouping.q 78560978ccb84c0737decf45cb56810195be288d

>   ql/src/test/results/clientpositive/groupby_grouping_sets_grouping.q.out 6917dbabb96b5a582416ac7f07968b739823a13f

> 
> 
> Diff: https://reviews.apache.org/r/57094/diff/1/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Jesús Camacho Rodríguez
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message