Merging upstream version 21.1.1.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
4e41aa0bbb
commit
bf03050a25
91 changed files with 49165 additions and 47854 deletions
38
tests/fixtures/optimizer/tpc-h/tpc-h.sql
vendored
38
tests/fixtures/optimizer/tpc-h/tpc-h.sql
vendored
|
@ -15,7 +15,7 @@ select
|
|||
from
|
||||
lineitem
|
||||
where
|
||||
l_shipdate <= date '1998-12-01' - interval '90' day
|
||||
CAST(l_shipdate AS DATE) <= date '1998-12-01' - interval '90' day
|
||||
group by
|
||||
l_returnflag,
|
||||
l_linestatus
|
||||
|
@ -218,8 +218,8 @@ select
|
|||
from
|
||||
orders
|
||||
where
|
||||
o_orderdate >= date '1993-07-01'
|
||||
and o_orderdate < date '1993-07-01' + interval '3' month
|
||||
CAST(o_orderdate AS DATE) >= date '1993-07-01'
|
||||
and CAST(o_orderdate AS DATE) < date '1993-07-01' + interval '3' month
|
||||
and exists (
|
||||
select
|
||||
*
|
||||
|
@ -278,8 +278,8 @@ where
|
|||
and s_nationkey = n_nationkey
|
||||
and n_regionkey = r_regionkey
|
||||
and r_name = 'ASIA'
|
||||
and o_orderdate >= date '1994-01-01'
|
||||
and o_orderdate < date '1994-01-01' + interval '1' year
|
||||
and CAST(o_orderdate AS DATE) >= date '1994-01-01'
|
||||
and CAST(o_orderdate AS DATE) < date '1994-01-01' + interval '1' year
|
||||
group by
|
||||
n_name
|
||||
order by
|
||||
|
@ -316,8 +316,8 @@ select
|
|||
from
|
||||
lineitem
|
||||
where
|
||||
l_shipdate >= date '1994-01-01'
|
||||
and l_shipdate < date '1994-01-01' + interval '1' year
|
||||
CAST(l_shipdate AS DATE) >= date '1994-01-01'
|
||||
and CAST(l_shipdate AS DATE) < date '1994-01-01' + interval '1' year
|
||||
and l_discount between 0.06 - 0.01 and 0.06 + 0.01
|
||||
and l_quantity < 24;
|
||||
SELECT
|
||||
|
@ -362,7 +362,7 @@ from
|
|||
(n1.n_name = 'FRANCE' and n2.n_name = 'GERMANY')
|
||||
or (n1.n_name = 'GERMANY' and n2.n_name = 'FRANCE')
|
||||
)
|
||||
and l_shipdate between date '1995-01-01' and date '1996-12-31'
|
||||
and CAST(l_shipdate AS DATE) between date '1995-01-01' and date '1996-12-31'
|
||||
) as shipping
|
||||
group by
|
||||
supp_nation,
|
||||
|
@ -446,7 +446,7 @@ from
|
|||
and n1.n_regionkey = r_regionkey
|
||||
and r_name = 'AMERICA'
|
||||
and s_nationkey = n2.n_nationkey
|
||||
and o_orderdate between date '1995-01-01' and date '1996-12-31'
|
||||
and CAST(o_orderdate AS DATE) between date '1995-01-01' and date '1996-12-31'
|
||||
and p_type = 'ECONOMY ANODIZED STEEL'
|
||||
) as all_nations
|
||||
group by
|
||||
|
@ -574,8 +574,8 @@ from
|
|||
where
|
||||
c_custkey = o_custkey
|
||||
and l_orderkey = o_orderkey
|
||||
and o_orderdate >= date '1993-10-01'
|
||||
and o_orderdate < date '1993-10-01' + interval '3' month
|
||||
and CAST(o_orderdate AS DATE) >= date '1993-10-01'
|
||||
and CAST(o_orderdate AS DATE) < date '1993-10-01' + interval '3' month
|
||||
and l_returnflag = 'R'
|
||||
and c_nationkey = n_nationkey
|
||||
group by
|
||||
|
@ -714,8 +714,8 @@ where
|
|||
and l_shipmode in ('MAIL', 'SHIP')
|
||||
and l_commitdate < l_receiptdate
|
||||
and l_shipdate < l_commitdate
|
||||
and l_receiptdate >= date '1994-01-01'
|
||||
and l_receiptdate < date '1994-01-01' + interval '1' year
|
||||
and CAST(l_receiptdate AS DATE) >= date '1994-01-01'
|
||||
and CAST(l_receiptdate AS DATE) < date '1994-01-01' + interval '1' year
|
||||
group by
|
||||
l_shipmode
|
||||
order by
|
||||
|
@ -813,8 +813,8 @@ from
|
|||
part
|
||||
where
|
||||
l_partkey = p_partkey
|
||||
and l_shipdate >= date '1995-09-01'
|
||||
and l_shipdate < date '1995-09-01' + interval '1' month;
|
||||
and CAST(l_shipdate AS DATE) >= date '1995-09-01'
|
||||
and CAST(l_shipdate AS DATE) < date '1995-09-01' + interval '1' month;
|
||||
SELECT
|
||||
100.00 * SUM(
|
||||
CASE
|
||||
|
@ -844,8 +844,8 @@ with revenue (supplier_no, total_revenue) as (
|
|||
from
|
||||
lineitem
|
||||
where
|
||||
l_shipdate >= date '1996-01-01'
|
||||
and l_shipdate < date '1996-01-01' + interval '3' month
|
||||
CAST(l_shipdate AS DATE) >= date '1996-01-01'
|
||||
and CAST(l_shipdate AS DATE) < date '1996-01-01' + interval '3' month
|
||||
group by
|
||||
l_suppkey)
|
||||
select
|
||||
|
@ -1223,8 +1223,8 @@ where
|
|||
where
|
||||
l_partkey = ps_partkey
|
||||
and l_suppkey = ps_suppkey
|
||||
and l_shipdate >= date '1994-01-01'
|
||||
and l_shipdate < date '1994-01-01' + interval '1' year
|
||||
and CAST(l_shipdate AS DATE) >= date '1994-01-01'
|
||||
and CAST(l_shipdate AS DATE) < date '1994-01-01' + interval '1' year
|
||||
)
|
||||
)
|
||||
and s_nationkey = n_nationkey
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue