mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
MDEV-35475 Assertion `!rec_offs_nth_extern(offsets1, n)' failed in cmp_rec_rec_simple_field
Problem: ======= InnoDB wrongly stores the primary key field in externally stored off page during bulk insert operation. This leads to assert failure. Solution: ======== row_merge_buf_blob(): Should store the primary key fields inline. Store the variable length field data externally based on the row format of the table. row_merge_buf_write(): check whether the record size exceeds the maximum record size. row_merge_copy_blob_from_file(): Construct the tuple based on the variable length field
This commit is contained in:
@@ -484,7 +484,7 @@ ALTER TABLE t1 FORCE;
|
||||
let $page_size= `SELECT @@innodb_page_size`;
|
||||
let $error_code = 0;
|
||||
|
||||
if ($page_size == 4096) {
|
||||
if ($page_size <= 16384) {
|
||||
let $error_code = ER_TOO_BIG_ROWSIZE;
|
||||
}
|
||||
|
||||
@@ -593,4 +593,30 @@ INSERT INTO t1 VALUES(2,0);
|
||||
DELETE FROM t1;
|
||||
commit;
|
||||
DROP TABLE t1;
|
||||
|
||||
|
||||
if ($page_size >= 16384) {
|
||||
--echo #
|
||||
--echo # MDEV-35475 Assertion `!rec_offs_nth_extern(offsets1, n)'
|
||||
--echo # failed in cmp_rec_rec_simple_field
|
||||
--echo #
|
||||
CREATE TABLE t1(a BLOB, b VARCHAR(2048), PRIMARY KEY (b)) ENGINE=InnoDB;
|
||||
INSERT INTO t1 VALUES (REPEAT('x',4805),'a'), (REPEAT('x',16111),'b'),
|
||||
(REPEAT('x',65535),'c'), (REPEAT('x',11312),'d'),
|
||||
(REPEAT('x',35177),'e'), (REPEAT('x',65535),'f'),
|
||||
(REPEAT('x',1988),'g'), (NULL,REPEAT('x',2048)),
|
||||
(REPEAT('x',2503),'h'), (REPEAT('x',33152),'i'),
|
||||
(REPEAT('x',65535),'j'), (REPEAT('x',1988),'k'),
|
||||
(REPEAT('x',65535),'l'), (REPEAT('x',65535),'m'),
|
||||
(REPEAT('x',65535),'n'), (REPEAT('x',65535),'o'),
|
||||
(REPEAT('x',1988),'p'), (REPEAT('x',2503),'q'),
|
||||
(REPEAT('x',65535),'r'), (REPEAT('x',65535),'s'),
|
||||
(REPEAT('x',65535),'t'), (REPEAT('x',3169),'u'),
|
||||
(REPEAT('x',7071),'v'), (REPEAT('x',16111),'w'),
|
||||
(REPEAT('x',2325),'x'), (REPEAT('x',33152),'y'),
|
||||
(REPEAT('x',65535),'z'), (REPEAT('x',65535),'aa'),
|
||||
(REPEAT('x',16111),'bb'), (REPEAT('x',4805),'cc'),
|
||||
(REPEAT('x',65535),'dd');
|
||||
DROP TABLE t1;
|
||||
}
|
||||
--echo # End of 10.11 tests
|
||||
|
Reference in New Issue
Block a user