From b417ef015fcaa9e407c292cf02984a6c1abd86db Mon Sep 17 00:00:00 2001 From: Alexey Milovidov Date: Tue, 9 Jun 2015 23:56:40 +0300 Subject: [PATCH] dbms: added test [#METR-16762]. --- .../00169_join_constant_keys.reference | 3 +++ .../0_stateless/00169_join_constant_keys.sql | 17 +++++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 dbms/tests/queries/0_stateless/00169_join_constant_keys.reference create mode 100644 dbms/tests/queries/0_stateless/00169_join_constant_keys.sql diff --git a/dbms/tests/queries/0_stateless/00169_join_constant_keys.reference b/dbms/tests/queries/0_stateless/00169_join_constant_keys.reference new file mode 100644 index 00000000000..f957808e94b --- /dev/null +++ b/dbms/tests/queries/0_stateless/00169_join_constant_keys.reference @@ -0,0 +1,3 @@ +1 0 999 +2 0 999 +3 0 999 diff --git a/dbms/tests/queries/0_stateless/00169_join_constant_keys.sql b/dbms/tests/queries/0_stateless/00169_join_constant_keys.sql new file mode 100644 index 00000000000..93c98271ca7 --- /dev/null +++ b/dbms/tests/queries/0_stateless/00169_join_constant_keys.sql @@ -0,0 +1,17 @@ +SELECT + key1, + key2, + table_1 +FROM +( + SELECT + arrayJoin([1, 2, 3]) AS key1, + 0 AS key2, + 999 AS table_1 +) ALL INNER JOIN +( + SELECT + arrayJoin([1, 3, 2]) AS key1, + 0 AS key2, + 999 AS table_1 +) USING key2, key1;