ClickHouse/dbms/tests/queries/0_stateless/00373_group_by_tuple.sql
2016-09-23 05:09:23 +03:00

3 lines
197 B
SQL

SELECT if(number % 2, tuple(0, 'Hello'), tuple(1, 'World')) AS x, count() FROM (SELECT number FROM system.numbers LIMIT 10) GROUP BY x ORDER BY x;
SELECT if(0, tuple(0), tuple(1)) AS x GROUP BY x;