From e082dbdd35d528c886418392b1428073c020669b Mon Sep 17 00:00:00 2001 From: Pavel Semenov <37123349+Atri0@users.noreply.github.com> Date: Tue, 3 Sep 2019 18:00:56 +0300 Subject: [PATCH] Test for parseError using WITH and UNION ALL operators (#593) * Test for parseError using WITH and UNION ALL operators * Fix use statement in the test. --- .../union_all/prq_union_all/prqUAllprq_36.e_tsv | 2 ++ .../Functional/union_all/prq_union_all/prqUAllprq_36.sql | 9 +++++++++ 2 files changed, 11 insertions(+) create mode 100644 framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.e_tsv create mode 100644 framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.sql diff --git a/framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.e_tsv b/framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.e_tsv new file mode 100644 index 000000000..1191247b6 --- /dev/null +++ b/framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.e_tsv @@ -0,0 +1,2 @@ +1 +2 diff --git a/framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.sql b/framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.sql new file mode 100644 index 000000000..89d62880c --- /dev/null +++ b/framework/resources/Functional/union_all/prq_union_all/prqUAllprq_36.sql @@ -0,0 +1,9 @@ +drop table if exists dfs.union_all.`MyTbl_1`; +drop table if exists dfs.union_all.`MyTbl_2`; +drop view if exists dfs.union_all.`MyView1`; +create table dfs.union_all.MyTbl_1 as (select 1 as Col); +create table dfs.union_all.MyTbl_2 as (select 2 as Col); +use dfs.union_all; +create or replace view dfs.union_all.MyView1 as with `tbl_un` as (select Col from MyTbl_1 union all select Col from MyTbl_2) select * from `tbl_un`; +--@test +select * from dfs.union_all.MyView1;