2020-06-17 19:36:27 +00:00
|
|
|
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);
|
2020-06-19 20:13:07 +00:00
|
|
|
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));
|
|
|
|
|
2020-06-22 14:55:49 +00:00
|
|
|
SELECT sum(DISTINCT y) FROM (SELECT number % 5 AS x, number % 15 AS y FROM numbers(1000)) GROUP BY x;
|
2020-06-19 20:13:07 +00:00
|
|
|
|
2020-06-22 14:55:49 +00:00
|
|
|
SELECT countIf(DISTINCT number % 10, number % 5 = 2) FROM numbers(10000);
|
2020-11-02 12:47:12 +00:00
|
|
|
EXPLAIN SYNTAX SELECT countIf(DISTINCT number % 10, number % 5 = 2) FROM numbers(10000);
|
2020-06-22 14:55:49 +00:00
|
|
|
|
|
|
|
SELECT sumIf(DISTINCT number % 10, number % 5 = 2) FROM numbers(10000);
|
2020-11-02 12:47:12 +00:00
|
|
|
EXPLAIN SYNTAX SELECT sumIf(DISTINCT number % 10, number % 5 = 2) FROM numbers(10000);
|