ClickHouse/tests/queries/0_stateless/03215_udf_with_union.sql
2024-08-02 11:13:41 +02:00

15 lines
267 B
SQL

DROP FUNCTION IF EXISTS 03215_udf_with_union;
CREATE FUNCTION 03215_udf_with_union AS () -> (
SELECT sum(s)
FROM
(
SELECT 1 AS s
UNION ALL
SELECT 1 AS s
)
);
SELECT 03215_udf_with_union();
DROP FUNCTION 03215_udf_with_union;