spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ayan guha <guha.a...@gmail.com>
Subject Re: Grouping Set
Date Mon, 14 Nov 2016 20:48:18 GMT
It should be A,yes. Can you please reproduce this with small data and exact
SQL?
On 15 Nov 2016 02:21, "Andrés Ivaldi" <iaivaldi@gmail.com> wrote:

> 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