MDEV-18904 Assertion `m_part_spec.start_part >= m_part_spec.end_part' failed in ha_partition::index_read_idx_map

Remove the DBUG_ASSERT
This commit is contained in:
Sachin 2019-03-22 14:54:24 +05:30
parent 0c567648a4
commit 901e3ddf79
3 changed files with 13 additions and 6 deletions

View File

@ -235,3 +235,7 @@ ERROR 23000: Duplicate entry '
insert into t1 values ('ббб');
ERROR 23000: Duplicate entry 'Ð' for key 'a'
drop table t1;
CREATE TABLE t1 (a INT, UNIQUE USING HASH (a)) PARTITION BY HASH (a) PARTITIONS 2;
INSERT INTO t1 VALUES (2);
REPLACE INTO t1 VALUES (2);
DROP TABLE t1;

View File

@ -265,3 +265,12 @@ insert into t1 values ('бб');
--error ER_DUP_ENTRY
insert into t1 values ('ббб');
drop table t1;
#
# MDEV-18904 Assertion `m_part_spec.start_part >= m_part_spec.end_part' failed in ha_partition::index_read_idx_map
#
--source include/have_partition.inc
CREATE TABLE t1 (a INT, UNIQUE USING HASH (a)) PARTITION BY HASH (a) PARTITIONS 2;
INSERT INTO t1 VALUES (2);
REPLACE INTO t1 VALUES (2);
DROP TABLE t1;

View File

@ -5759,12 +5759,6 @@ int ha_partition::index_read_idx_map(uchar *buf, uint index,
get_partition_set(table, buf, index, &m_start_key, &m_part_spec);
/*
We have either found exactly 1 partition
(in which case start_part == end_part)
or no matching partitions (start_part > end_part)
*/
DBUG_ASSERT(m_part_spec.start_part >= m_part_spec.end_part);
/* The start part is must be marked as used. */
DBUG_ASSERT(m_part_spec.start_part > m_part_spec.end_part ||
bitmap_is_set(&(m_part_info->read_partitions),