Skip to content

Commit 30a693c

Browse files
author
Bert Vermeiren
committed
Fix: filter with limit support raises internal error (slt test)
1 parent ec974ee commit 30a693c

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

datafusion/sqllogictest/test_files/limit.slt

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -872,3 +872,25 @@ DROP TABLE test_limit_with_partitions;
872872
# Tear down src_table table:
873873
statement ok
874874
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+

0 commit comments

Comments
 (0)