Skip to content

Commit

Permalink
fix Incorrect NULL handling in BETWEEN expression
Browse files Browse the repository at this point in the history
  • Loading branch information
getChan committed Jan 5, 2025
1 parent 5cc59ce commit b722dde
Show file tree
Hide file tree
Showing 211 changed files with 5,183 additions and 20,768 deletions.
475 changes: 95 additions & 380 deletions data/sqlite/index/random/10/slt_good_0.slt

Large diffs are not rendered by default.

525 changes: 105 additions & 420 deletions data/sqlite/index/random/10/slt_good_1.slt

Large diffs are not rendered by default.

375 changes: 75 additions & 300 deletions data/sqlite/index/random/10/slt_good_10.slt

Large diffs are not rendered by default.

425 changes: 85 additions & 340 deletions data/sqlite/index/random/10/slt_good_11.slt

Large diffs are not rendered by default.

350 changes: 70 additions & 280 deletions data/sqlite/index/random/10/slt_good_12.slt

Large diffs are not rendered by default.

400 changes: 80 additions & 320 deletions data/sqlite/index/random/10/slt_good_13.slt

Large diffs are not rendered by default.

400 changes: 80 additions & 320 deletions data/sqlite/index/random/10/slt_good_14.slt

Large diffs are not rendered by default.

350 changes: 70 additions & 280 deletions data/sqlite/index/random/10/slt_good_2.slt

Large diffs are not rendered by default.

375 changes: 75 additions & 300 deletions data/sqlite/index/random/10/slt_good_3.slt

Large diffs are not rendered by default.

400 changes: 80 additions & 320 deletions data/sqlite/index/random/10/slt_good_4.slt

Large diffs are not rendered by default.

325 changes: 65 additions & 260 deletions data/sqlite/index/random/10/slt_good_5.slt

Large diffs are not rendered by default.

275 changes: 55 additions & 220 deletions data/sqlite/index/random/10/slt_good_6.slt

Large diffs are not rendered by default.

425 changes: 85 additions & 340 deletions data/sqlite/index/random/10/slt_good_7.slt

Large diffs are not rendered by default.

325 changes: 65 additions & 260 deletions data/sqlite/index/random/10/slt_good_8.slt

Large diffs are not rendered by default.

400 changes: 80 additions & 320 deletions data/sqlite/index/random/10/slt_good_9.slt

Large diffs are not rendered by default.

325 changes: 65 additions & 260 deletions data/sqlite/index/random/100/slt_good_0.slt

Large diffs are not rendered by default.

500 changes: 100 additions & 400 deletions data/sqlite/index/random/100/slt_good_1.slt

Large diffs are not rendered by default.

50 changes: 10 additions & 40 deletions data/sqlite/index/random/1000/slt_good_0.slt
Original file line number Diff line number Diff line change
Expand Up @@ -4348,46 +4348,31 @@ SELECT DISTINCT + - 53 + + COUNT ( * ) FROM tab4 AS cor0 WHERE col2 IS NOT NULL
----
947

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-200
SELECT - COUNT ( + col1 ) AS col4 FROM tab0 AS cor0 WHERE NOT NULL BETWEEN ( NULL ) AND 39
----
0

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-200
SELECT - COUNT ( + col1 ) AS col4 FROM tab1 AS cor0 WHERE NOT NULL BETWEEN ( NULL ) AND 39
----
0

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-200
SELECT - COUNT ( + col1 ) AS col4 FROM tab2 AS cor0 WHERE NOT NULL BETWEEN ( NULL ) AND 39
----
0

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-200
SELECT - COUNT ( + col1 ) AS col4 FROM tab3 AS cor0 WHERE NOT NULL BETWEEN ( NULL ) AND 39
----
0

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-200
SELECT - COUNT ( + col1 ) AS col4 FROM tab4 AS cor0 WHERE NOT NULL BETWEEN ( NULL ) AND 39
----
Expand Down Expand Up @@ -5773,42 +5758,27 @@ SELECT 25 FROM tab4 AS cor0 WHERE + + col3 * - col1 IS NOT NULL OR 69 >= + col3
----
1000 values hashing to 7ab27497c121866e93dc81537b56ecc8

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-425
SELECT col0 + - 82 FROM tab0 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - 64 * + 41 * 10
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-425
SELECT col0 + - 82 FROM tab1 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - 64 * + 41 * 10
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-425
SELECT col0 + - 82 FROM tab2 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - 64 * + 41 * 10
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-425
SELECT col0 + - 82 FROM tab3 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - 64 * + 41 * 10
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-425
SELECT col0 + - 82 FROM tab4 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - 64 * + 41 * 10
----
Expand Down
75 changes: 15 additions & 60 deletions data/sqlite/index/random/1000/slt_good_5.slt
Original file line number Diff line number Diff line change
Expand Up @@ -9363,42 +9363,27 @@ query IIRTIRT rowsort label-1005
SELECT ALL * FROM tab4 AS cor0 WHERE - col0 * + col4 > NULL
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1010
SELECT - col1 * - col0 FROM tab0 AS cor0 WHERE NULL NOT BETWEEN NULL AND - col3 + - 86
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1010
SELECT - col1 * - col0 FROM tab1 AS cor0 WHERE NULL NOT BETWEEN NULL AND - col3 + - 86
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1010
SELECT - col1 * - col0 FROM tab2 AS cor0 WHERE NULL NOT BETWEEN NULL AND - col3 + - 86
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1010
SELECT - col1 * - col0 FROM tab3 AS cor0 WHERE NULL NOT BETWEEN NULL AND - col3 + - 86
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1010
SELECT - col1 * - col0 FROM tab4 AS cor0 WHERE NULL NOT BETWEEN NULL AND - col3 + - 86
----
Expand Down Expand Up @@ -14118,42 +14103,27 @@ query I rowsort label-1760
SELECT col2 FROM tab4 AS cor0 WHERE ( NULL ) NOT BETWEEN NULL AND - col3 * col4 - - + col4
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1765
SELECT ( + col4 ) AS col5 FROM tab0 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND 38
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1765
SELECT ( + col4 ) AS col5 FROM tab1 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND 38
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1765
SELECT ( + col4 ) AS col5 FROM tab2 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND 38
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1765
SELECT ( + col4 ) AS col5 FROM tab3 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND 38
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query I rowsort label-1765
SELECT ( + col4 ) AS col5 FROM tab4 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND 38
----
Expand Down Expand Up @@ -18763,42 +18733,27 @@ query IIRTIRT rowsort label-2540
SELECT * FROM tab4 AS cor0 WHERE NOT ( NOT NULL IS NOT NULL )
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query IIIIIII rowsort label-2545
SELECT * FROM tab0 WHERE NULL BETWEEN NULL AND - 39
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query IIIIIII rowsort label-2545
SELECT * FROM tab1 WHERE NULL BETWEEN NULL AND - 39
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query IIIIIII rowsort label-2545
SELECT * FROM tab2 WHERE NULL BETWEEN NULL AND - 39
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query IIIIIII rowsort label-2545
SELECT * FROM tab3 WHERE NULL BETWEEN NULL AND - 39
----

# Datafusion - DataFusion error: type_coercion
# Datafusion - caused by
# Datafusion - Error during planning: Cannot automatically convert Int64 to Null
skipif Datafusion

query IIIIIII rowsort label-2545
SELECT * FROM tab4 WHERE NULL BETWEEN NULL AND - 39
----
Expand Down
Loading

0 comments on commit b722dde

Please sign in to comment.