ClickHouse/tests/queries/0_stateless/02416_grouping_function_compatibility.reference

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

30 lines
461 B
Plaintext
Raw Normal View History

2022-09-01 15:19:29 +00:00
-- { echoOn }
SELECT count() AS amount, a, b, GROUPING(a, b) FROM test02416 GROUP BY GROUPING SETS ((a, b), (a), ()) ORDER BY (amount, a, b);
1 0 0 0
1 0 2 0
1 0 4 0
1 0 6 0
1 0 8 0
1 1 1 0
1 1 3 0
1 1 5 0
1 1 7 0
1 1 9 0
5 0 0 1
5 1 0 1
10 0 0 3
SELECT count() AS amount, a, b, GROUPING(a, b) FROM test02416 GROUP BY ROLLUP(a, b) ORDER BY (amount, a, b);
1 0 0 0
1 0 2 0
1 0 4 0
1 0 6 0
1 0 8 0
1 1 1 0
1 1 3 0
1 1 5 0
1 1 7 0
1 1 9 0
5 0 0 1
5 1 0 1
10 0 0 3