ClickHouse/tests/queries/0_stateless/01479_cross_join_9855.sql
2023-06-05 22:09:32 +02:00

10 lines
365 B
SQL

SET cross_to_inner_join_rewrite = 1;
SELECT count()
FROM numbers(4) AS n1, numbers(3) AS n2
WHERE n1.number > (select avg(n.number) from numbers(3) n) SETTINGS allow_experimental_analyzer=0;
SELECT count()
FROM numbers(4) AS n1, numbers(3) AS n2, numbers(6) AS n3
WHERE n1.number > (select avg(n.number) from numbers(3) n) SETTINGS allow_experimental_analyzer=0;