diff options
author | Daniel Black <daniel@mariadb.org> | 2021-03-24 15:41:10 +1100 |
---|---|---|
committer | Daniel Black <daniel@mariadb.org> | 2021-04-08 16:51:36 +1000 |
commit | 058484687aa49326b8a7909499e7a8d1aba02953 (patch) | |
tree | 27d1dbef16c0043cfdf4051d6f4fa2ea1b925eed /sql/records.cc | |
parent | cf552f5886968fc022122960d3a9274ce9f27819 (diff) | |
download | mariadb-git-058484687aa49326b8a7909499e7a8d1aba02953.tar.gz |
Add TL_FIRST_WRITE in SQL layer for determining R/W
Use < TL_FIRST_WRITE for determining a READ transaction.
Use TL_FIRST_WRITE as the relative operator replacing TL_WRITE_ALLOW_WRITE
as the minimium WRITE lock type.
Diffstat (limited to 'sql/records.cc')
-rw-r--r-- | sql/records.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/records.cc b/sql/records.cc index 77ee3c65321..09500b3acef 100644 --- a/sql/records.cc +++ b/sql/records.cc @@ -255,7 +255,7 @@ bool init_read_record(READ_RECORD *info,THD *thd, TABLE *table, thd->variables.read_rnd_buff_size && !(table->file->ha_table_flags() & HA_FAST_KEY_READ) && (table->db_stat & HA_READ_ONLY || - table->reginfo.lock_type <= TL_READ_NO_INSERT) && + table->reginfo.lock_type < TL_FIRST_WRITE) && (ulonglong) table->s->reclength* (table->file->stats.records+ table->file->stats.deleted) > (ulonglong) MIN_FILE_LENGTH_TO_USE_ROW_CACHE && |