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:
@@ -286,3 +286,53 @@ Table Op Msg_type Msg_text
|
||||
test.t1 check status OK
|
||||
test.t2 check status OK
|
||||
drop table t1,t2;
|
||||
#
|
||||
# MDEV-35475 Assertion `!rec_offs_nth_extern(offsets1, n)'
|
||||
# failed in cmp_rec_rec_simple_field
|
||||
#
|
||||
CREATE TABLE t1(f1 int not null, f2 text, f3 text, f4 text,
|
||||
f5 text, f6 text, f7 text, f8 text,
|
||||
f9 text, f10 text, f11 text, f12 text,
|
||||
f13 text, f14 text, f15 text, f16 text,
|
||||
f17 text, f18 text, f19 text, f20 text,
|
||||
f21 text, f22 text, f23 text, f24 text,
|
||||
f25 text, PRIMARY KEY(f1))ENGINE=InnoDB;
|
||||
SET STATEMENT unique_checks=0,foreign_key_checks=0 FOR
|
||||
INSERT INTO t1 VALUES(1, REPEAT('a', 1024), REPEAT('b', 1024),
|
||||
REPEAT('c', 1024), REPEAT('d', 1024),
|
||||
REPEAT('e', 1024), REPEAT('f', 1024),
|
||||
REPEAT('g', 4096), REPEAT('h', 1024),
|
||||
REPEAT('i', 1024), REPEAT('j', 1024),
|
||||
REPEAT('k', 1024), REPEAT('l', 1024),
|
||||
REPEAT('m', 1024), REPEAT('n', 1024),
|
||||
REPEAT('o', 1024), REPEAT('p', 1024),
|
||||
REPEAT('q', 1024), REPEAT('r', 1024),
|
||||
REPEAT('s', 1024), REPEAT('t', 1024),
|
||||
REPEAT('u', 1024), REPEAT('v', 1024),
|
||||
REPEAT('w', 1024), REPEAT('x', 1024)),
|
||||
(2, REPEAT('a', 1024), REPEAT('b', 1024),
|
||||
REPEAT('c', 1024), REPEAT('d', 1024),
|
||||
REPEAT('e', 1024), REPEAT('f', 1024),
|
||||
REPEAT('g', 4096), REPEAT('h', 1024),
|
||||
REPEAT('i', 1024), REPEAT('j', 1024),
|
||||
REPEAT('k', 1024), REPEAT('l', 1024),
|
||||
REPEAT('m', 1024), REPEAT('n', 1024),
|
||||
REPEAT('o', 1024), REPEAT('p', 1024),
|
||||
REPEAT('q', 1024), REPEAT('r', 1024),
|
||||
REPEAT('s', 1024), REPEAT('t', 1024),
|
||||
REPEAT('u', 1024), REPEAT('v', 1024),
|
||||
REPEAT('w', 1024), REPEAT('x', 1024)),
|
||||
(3, REPEAT('a', 1024), REPEAT('b', 1024),
|
||||
REPEAT('c', 1024), REPEAT('d', 1024),
|
||||
REPEAT('e', 1024), REPEAT('f', 1024),
|
||||
REPEAT('g', 4096), REPEAT('h', 1024),
|
||||
REPEAT('i', 1024), REPEAT('j', 1024),
|
||||
REPEAT('k', 1024), REPEAT('l', 1024),
|
||||
REPEAT('m', 1024), REPEAT('n', 1024),
|
||||
REPEAT('o', 1024), REPEAT('p', 1024),
|
||||
REPEAT('q', 1024), REPEAT('r', 1024),
|
||||
REPEAT('s', 1024), REPEAT('t', 1024),
|
||||
REPEAT('u', 1024), REPEAT('v', 1024),
|
||||
REPEAT('w', 1024), REPEAT('x', 1024));
|
||||
ERROR 42000: Row size too large (> 16383). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help. In current row format, BLOB prefix of 768 bytes is stored inline.
|
||||
DROP TABLE t1;
|
||||
|
Reference in New Issue
Block a user