ClickHouse/tests/queries/0_stateless/01281_sum_nullable.sql

7 lines
322 B
MySQL
Raw Normal View History

2020-05-18 05:03:58 +00:00
SELECT sumKahan(toFloat64(number)) FROM numbers(10);
SELECT sumKahan(toNullable(toFloat64(number))) FROM numbers(10);
SELECT sum(toNullable(number)) FROM numbers(10);
SELECT sum(x) FROM (SELECT 1 AS x UNION ALL SELECT NULL);
SELECT sum(number) FROM numbers(10);
SELECT sum(number < 1000 ? NULL : number) FROM numbers(10);