diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index 2de7c507dc3..5d9e42fa7d7 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -2487,7 +2487,7 @@ sub ndbcluster_start_install ($) { else { $ndb_no_ord=32; - $ndb_con_op=5000; + $ndb_con_op=10000; $ndb_dmem="20M"; $ndb_imem="1M"; $ndb_pbmem="4M"; diff --git a/mysql-test/r/ndb_row_format.result b/mysql-test/r/ndb_row_format.result index 6db289c75aa..ae165d87c5c 100644 --- a/mysql-test/r/ndb_row_format.result +++ b/mysql-test/r/ndb_row_format.result @@ -37,3 +37,29 @@ ROW_FORMAT=DYNAMIC ENGINE=NDB; ForceVarPart: 1 DROP TABLE t1; +create table t1 (a int auto_increment primary key, b varchar(1000)) engine = ndb; +insert into t1(b) values ('0123456789'); +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +select count(*) from t1; +count(*) +1024 +begin; +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +rollback; +select count(*),b from t1 group by b; +count(*) b +1024 0123456789 +drop table t1; diff --git a/mysql-test/t/ndb_row_format.test b/mysql-test/t/ndb_row_format.test index 9668d8ea515..b1582cbe339 100644 --- a/mysql-test/t/ndb_row_format.test +++ b/mysql-test/t/ndb_row_format.test @@ -60,3 +60,27 @@ CREATE TABLE t1 ENGINE=NDB; --exec $NDB_TOOLS_DIR/ndb_desc --no-defaults -d test t1 | grep ForceVarPart DROP TABLE t1; + +# test of bug +create table t1 (a int auto_increment primary key, b varchar(1000)) engine = ndb; +insert into t1(b) values ('0123456789'); +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +insert into t1(b) select b from t1; +select count(*) from t1; +begin; +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +update t1 set b = concat(b,b); +rollback; +select count(*),b from t1 group by b; +drop table t1; diff --git a/storage/ndb/src/kernel/blocks/dbtup/DbtupExecQuery.cpp b/storage/ndb/src/kernel/blocks/dbtup/DbtupExecQuery.cpp index ce337afb20b..69b2d6d116e 100644 --- a/storage/ndb/src/kernel/blocks/dbtup/DbtupExecQuery.cpp +++ b/storage/ndb/src/kernel/blocks/dbtup/DbtupExecQuery.cpp @@ -2846,6 +2846,12 @@ Dbtup::handle_size_change_after_update(KeyReqStruct* req_struct, if (unlikely(realloc_var_part(regFragPtr, regTabPtr, pagePtr, refptr, alloc, needed))) return -1; + + if (regTabPtr->m_bits & Tablerec::TR_Checksum) + { + jam(); + setChecksum(org, regTabPtr); + } } req_struct->m_tuple_ptr->m_header_bits = copy_bits; return 0;