I got server crash due to assert failure at ATTACHing overlap rang
partition, here is test case to reproduce this:
CREATE TABLE test_parent(a int) PARTITION BY RANGE (a);
CREATE TABLE test_parent_part2 PARTITION OF test_parent FOR VALUES
CREATE TABLE test_parent_part1(a int NOT NULL);
ALTER TABLE test_parent ATTACH PARTITION test_parent_part1 FOR VALUES
I think, this bug exists in the following code of check_new_partition_bound():
767 if (equal || off1 != off2)
769 overlap = true;
770 with = boundinfo->indexes[off2 + 1];
When equal is true array index should not be 'off2 + 1'.
While reading code related to this, I wondered why
partition_bound_bsearch is not immediately returns when cmpval==0?
Apologise if this has been already reported.
Sent via pgsql-hackers mailing list (email@example.com)
To make changes to your subscription: