Skip to content

Commit

Permalink
MDEV-22384 Wrong estimate of affected BLOB columns in update of PRIMA…
Browse files Browse the repository at this point in the history
…RY KEY

During the UPDATE of PRIMARY KEY columns, we may miscalculate the
size of the clustered index record.

row_upd_clust_rec_by_insert(): Pass the total number of off-page columns,
which may include such columns that were inherited from the record
and not created as part of the UPDATE operation.

This is based on
mysql/mysql-server@490c45e
which is a follow-up to
mysql/mysql-server@1fa475b
which we filed and fixed as MDEV-21511.

No test case was provided by Oracle.
  • Loading branch information
dr-m committed Apr 28, 2020
1 parent 547cb28 commit 2644e52
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions storage/innobase/row/row0upd.cc
Expand Up @@ -2805,8 +2805,7 @@ row_upd_clust_rec_by_insert(
mtr_commit(mtr);

err = row_ins_clust_index_entry(
index, entry, thr,
node->upd_ext ? node->upd_ext->n_ext : 0);
index, entry, thr, dtuple_get_n_ext(entry));
node->state = UPD_NODE_INSERT_CLUSTERED;

mem_heap_free(heap);
Expand Down

0 comments on commit 2644e52

Please sign in to comment.