Skip to content

Commit fc37c87

Browse files
author
Bert Vermeiren
committed
Fix: filter with limit support raises internal error (tackled review comments)
1 parent b2b8a23 commit fc37c87

2 files changed

Lines changed: 23 additions & 23 deletions

File tree

datafusion/sqllogictest/test_files/limit.slt

Lines changed: 1 addition & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -871,26 +871,4 @@ DROP TABLE test_limit_with_partitions;
871871

872872
# Tear down src_table table:
873873
statement ok
874-
DROP TABLE src_table;
875-
876-
877-
878-
# tests with target partition set to 1
879-
statement ok
880-
set datafusion.execution.target_partitions = '1';
881-
882-
# minimize batch size to minimize test data
883-
statement ok
884-
set datafusion.execution.batch_size = '1';
885-
886-
statement ok
887-
CREATE TABLE filter_limit (i INT) as values (1), (2);
888-
889-
query I
890-
SELECT COUNT(*) FROM (SELECT i FROM filter_limit WHERE i <> 0 LIMIT 1);
891-
----
892-
1
893-
894-
statement ok
895-
DROP TABLE filter_limit;
896-
874+
DROP TABLE src_table;
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
2+
# minimize batch size to 1 in order to trigger different code paths
3+
statement ok
4+
set datafusion.execution.batch_size = '1';
5+
6+
# ----
7+
# tests with target partition set to 1
8+
# ----
9+
statement ok
10+
set datafusion.execution.target_partitions = '1';
11+
12+
13+
statement ok
14+
CREATE TABLE filter_limit (i INT) as values (1), (2);
15+
16+
query I
17+
SELECT COUNT(*) FROM (SELECT i FROM filter_limit WHERE i <> 0 LIMIT 1);
18+
----
19+
1
20+
21+
statement ok
22+
DROP TABLE filter_limit;

0 commit comments

Comments
 (0)