Skip to content

Commit 8b666b7

Browse files
TPCH query errors (MaterializeInc#3394)
Correct errors in our TPCH queries.
1 parent 1f3c657 commit 8b666b7

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

test/sqllogictest/tpch.slt

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -674,7 +674,7 @@ FROM
674674
AND p_partkey = l_partkey
675675
AND o_orderkey = l_orderkey
676676
AND s_nationkey = n_nationkey
677-
AND p_name like 'green'
677+
AND p_name like '%green%'
678678
) AS profit
679679
GROUP BY
680680
nation,
@@ -711,7 +711,7 @@ ORDER BY
711711
| Join %0 %1 %2 %3 %4 %5 (= #9 #18 #33) (= #0 #17 #32) (= #16 #37) (= #12 #46)
712712
| | implementation = DeltaQuery %0 %2.(#1) %3.(#0, #1) %1.(#0) %4.(#0) %5.(#0) | %1 %5.(#0) %2.(#2) %3.(#0, #1) %0.(#0) %4.(#0) | %2 %3.(#0, #1) %0.(#0) %1.(#0) %4.(#0) %5.(#0) | %3 %0.(#0) %1.(#0) %5.(#0) %2.(#1, #2) %4.(#0) | %4 %2.(#0) %3.(#0, #1) %0.(#0) %1.(#0) %5.(#0) | %5 %1.(#3) %2.(#2) %3.(#0, #1) %0.(#0) %4.(#0)
713713
| | demand = (#1, #20..#22, #35, #41, #47)
714-
| Filter "^green$" ~(#1)
714+
| Filter "^.*green.*$" ~(#1)
715715
| Reduce group=(#47, tsextractyear(datetots(#41))) sum(((#21 * (100dec - #22)) - (#35 * #20)))
716716

717717
Finish order_by=(#0 asc, #1 desc) limit=none offset=0 project=(#0..#2)
@@ -1001,8 +1001,8 @@ FROM
10011001
part
10021002
WHERE
10031003
l_partkey = p_partkey
1004-
AND l_shipdate >= DATE '1996-01-01'
1005-
AND l_shipdate < DATE '1996-01-01' + INTERVAL '1' month
1004+
AND l_shipdate >= DATE '1995-09-01'
1005+
AND l_shipdate < DATE '1995-09-01' + INTERVAL '1' month
10061006
----
10071007
%0 =
10081008
| Get materialize.public.lineitem (u21)
@@ -1016,7 +1016,7 @@ WHERE
10161016
| Join %0 %1 (= #1 #16)
10171017
| | implementation = DeltaQuery %0 %1.(#0) | %1 %0.(#1)
10181018
| | demand = (#5, #6, #10, #20)
1019-
| Filter (datetots(#10) < 1996-02-01 00:00:00), (#10 >= 1996-01-01)
1019+
| Filter (datetots(#10) < 1995-10-01 00:00:00), (#10 >= 1995-09-01)
10201020
| Reduce group=() sum(if "^PROMO.*$" ~(#20) then {(#5 * (100dec - #6))} else {0dec}) sum((#5 * (100dec - #6)))
10211021

10221022
%3 =
@@ -1713,7 +1713,7 @@ FROM
17131713
customer
17141714
WHERE
17151715
substring(c_phone, 1, 2)
1716-
IN (':1', ':2', ':3', ':4', ':5', ':6', ':7')
1716+
IN ('13', '31', '23', '29', '30', '18', '17')
17171717
AND c_acctbal
17181718
> (
17191719
SELECT
@@ -1751,7 +1751,7 @@ ORDER BY
17511751
----
17521752
%0 =
17531753
| Get materialize.public.customer (u15)
1754-
| Filter (((((((substr(#4, 1, 2) = ":1") || (substr(#4, 1, 2) = ":2")) || (substr(#4, 1, 2) = ":3")) || (substr(#4, 1, 2) = ":4")) || (substr(#4, 1, 2) = ":5")) || (substr(#4, 1, 2) = ":6")) || (substr(#4, 1, 2) = ":7"))
1754+
| Filter (((((((substr(#4, 1, 2) = "13") || (substr(#4, 1, 2) = "31")) || (substr(#4, 1, 2) = "23")) || (substr(#4, 1, 2) = "29")) || (substr(#4, 1, 2) = "30")) || (substr(#4, 1, 2) = "18")) || (substr(#4, 1, 2) = "17"))
17551755

17561756
%1 =
17571757
| Get materialize.public.customer (u15)

0 commit comments

Comments
 (0)