mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-29 19:12:03 +00:00
9 lines
608 B
SQL
9 lines
608 B
SQL
SELECT sum(DISTINCT number) FROM numbers_mt(100000);
|
|
SELECT sum(DISTINCT number % 13) FROM numbers_mt(100000);
|
|
SELECT arraySort(groupArray(DISTINCT number % 13)) FROM numbers_mt(100000);
|
|
SELECT finalizeAggregation(countState(DISTINCT toString(number % 20))) FROM numbers_mt(100000);
|
|
SELECT round(corrStable(DISTINCT x, y), 5) FROM (SELECT number % 10 AS x, number % 5 AS y FROM numbers(1000));
|
|
SELECT round(corrStable(x, y), 5) FROM (SELECT DISTINCT number % 10 AS x, number % 5 AS y FROM numbers(1000));
|
|
|
|
|
|
SELECT sum(DISTINCT y) FROM (SELECT number % 5 AS x, number % 15 AS y FROM numbers(1000)) GROUP BY x; |