From 7b5654f3e987dcbaa8cb0fdfd3486ffb3fc4f8e3 Mon Sep 17 00:00:00 2001 From: Alexey Botchkov Date: Wed, 20 Nov 2019 00:33:32 +0400 Subject: MDEV-14667 Assertion `used_parts > 0' failed in ha_partition::init_record_priority_queue. Do not fail fi all the partitions were pruned out. --- mysql-test/main/partition_pruning.test | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'mysql-test/main/partition_pruning.test') diff --git a/mysql-test/main/partition_pruning.test b/mysql-test/main/partition_pruning.test index 1770f028f31..6b861621e0d 100644 --- a/mysql-test/main/partition_pruning.test +++ b/mysql-test/main/partition_pruning.test @@ -1536,6 +1536,19 @@ select * from t1 where (a = 1 AND b < 'd' AND (c = 'b' OR (c = 'c' AND d = 1)) O (a = 1 AND b >= 'a' AND (c = 'c' OR (c = 'd' AND d = 2)))); drop table t1; +--echo # +--echo # MDEV-14667 Assertion `used_parts > 0' failed in ha_partition::init_record_priority_queue. +--echo # + +create table t1 (a int); +insert into t1 values (1),(2); + +create table t2 (b int, c int, key(c,b)) partition by hash(b) partitions 2; +insert into t2 values (3,4),(5,6); + +select straight_join * from t1, t2 where b != NULL; +drop table t1, t2; + --echo # --echo # MDEV-17493: Partition pruning doesn't work for nested outer joins --echo # -- cgit v1.2.1