Skip to content
Permalink
Browse files
DRILL-7200: Baseline updates due to Calcite update (#590)
- After the Calcite update (1.20) a validation was added for duplicate aliases. Fixed by making them unique.
- Fixed plans where literals are now concatenated with type.
  • Loading branch information
agozhiy authored and Agirish committed Jul 5, 2019
1 parent 13f42bf commit c6c700c93617e62f89345332fbe87de55b7451c4
Showing 105 changed files with 108 additions and 108 deletions.
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$0, 999\.9\)\]\)
Filter\(condition=\[>\(\$0, 999\.9:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*numFiles=1.*numRowGroups=18.*usedMetadataFile=true.*columns=\[`ps_supplycost`, `ps_availqty`, `ps_comment`\]
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$0, 999\.9\)\]\)
Filter\(condition=\[>\(\$0, 999\.9:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*numFiles=1.*numRowGroups=18.*usedMetadataFile=false.*columns=\[`ps_supplycost`, `ps_availqty`, `ps_comment`\]
@@ -1,4 +1,4 @@
Filter\(condition=\[AND\(<=\(\$1, 1\), >=\(\$2, 0\.08\), <=\(\$2, 0\.09\), =\(\$3, 0\)\)\]\)
Filter\(condition=\[AND\(<=\(\$1, 1\), >=\(\$2, 0\.08:DECIMAL\(\d+, \d+\)\), <=\(\$2, 0\.09:DECIMAL\(\d+, \d+\)\), =\(\$3, 0\)\)\]\)
Scan.*numFiles=5.*numRowGroups=5.*usedMetadataFile=true.*columns=\[`l_partkey`, `l_quantity`, `l_discount`, `l_tax`, `l_suppkey`\]
.*
Filter\(condition=\[<\(\$1, 5\)\]\)
@@ -1,4 +1,4 @@
Filter\(condition=\[AND\(<=\(\$1, 1\), >=\(\$2, 0\.08\), <=\(\$2, 0\.09\), =\(\$3, 0\)\)\]\)
Filter\(condition=\[AND\(<=\(\$1, 1\), >=\(\$2, 0\.08:DECIMAL\(\d+, \d+\)\), <=\(\$2, 0\.09:DECIMAL\(\d+, \d+\)\), =\(\$3, 0\)\)\]\)
Scan.*numFiles=5.*numRowGroups=5.*usedMetadataFile=false.*columns=\[`l_partkey`, `l_quantity`, `l_discount`, `l_tax`, `l_suppkey`\]
.*
Filter\(condition=\[<\(\$1, 5\)\]\)
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$0, 94700\.999\)\]\)
Filter\(condition=\[>\(\$0, 94700\.999:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*numFiles=9.*numRowGroups=9.*usedMetadataFile=true.*columns=\[`l_extendedprice`, `l_orderkey`, `l_shipmode`, `l_tax`\]
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$0, 94700\.999\)\]\)
Filter\(condition=\[>\(\$0, 94700\.999:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*numFiles=9.*numRowGroups=9.*usedMetadataFile=false.*columns=\[`l_extendedprice`, `l_orderkey`, `l_shipmode`, `l_tax`\]
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$0, 1900\.989\)\]\)
Filter\(condition=\[>\(\$0, 1900\.989:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*numFiles=1.*numRowGroups=5.*usedMetadataFile=true.*columns=\[`p_retailprice`, `p_name`, `p_brand`\]
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$0, 1900\.989\)\]\)
Filter\(condition=\[>\(\$0, 1900\.989:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*numFiles=1.*numRowGroups=5.*usedMetadataFile=false.*columns=\[`p_retailprice`, `p_name`, `p_brand`\]
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$0, 1900\.989\)\]\)
Filter\(condition=\[>\(\$0, 1900\.989:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*numFiles=1.*numRowGroups=1.*usedMetadataFile=true.*columns=\[`p_retailprice`, `p_name`, `p_brand`\]
@@ -1,2 +1,2 @@
Filter\(condition=\[>\(\$1, 999\.9\)\]\)
Filter\(condition=\[>\(\$1, 999\.9:DECIMAL\(\d+, \d+\)\)\]\)
Scan.*HiveDrillNativeParquetScan.*numFiles=18.*numRowGroups=18.*columns=\[`ps_availqty`, `ps_supplycost`, `ps_comment`\]
@@ -1,7 +1,7 @@
SELECT *
FROM
(
SELECT t1.c4 , t2.c4
SELECT t1.c4 t1_c4, t2.c4 t2_c4
FROM `t_alltype.parquet` t1, `t_alltype.parquet` t2
WHERE t1.c4 = t2.c4 OR (t1.c4 IS NULL AND t2.c4 IS NULL)
ORDER BY t1.c4 nulls last
@@ -1,6 +1,6 @@
select * from
(
select t1.c4, t2.c4
select t1.c4 t1_c4, t2.c4 t2_c4
from `t_alltype.parquet` t1, `t_alltype.parquet` t2
WHERE t1.c4 = t2.c4 or (t1.c4 IS NULL AND t2.c4 IS NULL) ORDER BY t1.c4 NULLS LAST
);
@@ -14,10 +14,10 @@ select t1.a1,
count(distinct t2.b2) as distinct_b2,
count(distinct t1.c1) as distinct_c1,
count(distinct t2.c2) as distinct_c2,
sum(t1.a1) as sum_a1,
sum(t2.a2) as sum_a1,
avg(t1.a1) as sum_a1,
avg(t2.a2) as sum_a1,
sum(t1.a1) as sum_t1_a1,
sum(t2.a2) as sum_t2_a2,
avg(t1.a1) as avg_t1_a1,
avg(t2.a2) as avg_t2_a2,
count(t1.c1) as count_a1,
count(*) as count_star
from
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as case_in_sum_d18,
cast(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end) as bigint) as case_in_sum_d18,
--coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18
cast(coalesce(sum(case when a.d18 = 0 then 100 else round(a.d18/12) end), 0) as bigint) as case_in_sum_d18_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a
@@ -10,7 +10,7 @@ select
--sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as case_in_sum_d28,
cast(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end) as bigint) as case_in_sum_d28,
--coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28
cast(coalesce(sum(case when a.d28 = 0 then 100 else round(a.d28/12) end), 0) as bigint) as case_in_sum_d28_0

from
alltypes_with_nulls_v a