spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrés Ivaldi <iaiva...@gmail.com>
Subject Grouping Set
Date Mon, 14 Nov 2016 15:20:39 GMT
Hello, I'm tryin to use Grouping Set, but I dont know if it is a bug or the
correct behavior.

Givven the above example
Select a,b,sum(c) from table group by a,b grouping set ( (a), (a,b) )

What shound be the expected result
A:

A  | B    | sum(c)
xx | null | ####
xx | yy   | ####
xx | zz   | ####


B
A   | B    | sum(c)
xx  | null | ####
xx  | yy   | ####
xx  | zz   | ####
null| yy   | ####
null| zz   | ####
null| null | ####


I believe is A, but i'm getting B
thanks

-- 
Ing. Ivaldi Andres

Mime
View raw message