0

Following picture is illustrating the effect of hierarchy dimension reduction.

It reduces the number of cuboid from 2^N to N+1

enter image description here

With this dimension reduction, I wonder how following queries could give correct answer?

  1. select B, count(1) from X group by B
  2. select C, count(1) from X group by C
  3. select B,C,count(1) from X group by B,C
Tom
  • 5,848
  • 12
  • 44
  • 104

1 Answers1

0

Looks I found the answer: => means equal to

group by A,B => group by A,B
group by B,C => group by C => group by A,B,C
group by A,C => group by C => group by A,B,C
group by A => group by A
group by B => group by A,B
group by C => group by A,B,C
group by B,C => group by A,B,C
Tom
  • 5,848
  • 12
  • 44
  • 104