diff options
author | mats@mysql.com <> | 2005-02-18 13:50:19 +0100 |
---|---|---|
committer | mats@mysql.com <> | 2005-02-18 13:50:19 +0100 |
commit | d0f1b5f3fdd15a9e68785e7c57539c377c4a08c3 (patch) | |
tree | 341e4ffb07fb4c0865ca30da763750d3d2905662 /sql/sql_update.cc | |
parent | 4decbce5eacc677726632a0ef7c977cd68e3d14e (diff) | |
parent | 625f7f0d5565c90ce3d2ea3cf14706f28fc5c0e5 (diff) | |
download | mariadb-git-d0f1b5f3fdd15a9e68785e7c57539c377c4a08c3.tar.gz |
Merge mysql.com:/home/bkroot/mysql-4.0
into mysql.com:/home/bk/b7879-mysql-4.0
Diffstat (limited to 'sql/sql_update.cc')
-rw-r--r-- | sql/sql_update.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sql/sql_update.cc b/sql/sql_update.cc index b1b30a29639..b2b10a9b59a 100644 --- a/sql/sql_update.cc +++ b/sql/sql_update.cc @@ -473,7 +473,10 @@ int mysql_multi_update_lock(THD *thd, else { DBUG_PRINT("info",("setting table `%s` for read-only", tl->alias)); - tl->lock_type= TL_READ; + // If we are using the binary log, we need TL_READ_NO_INSERT to get + // correct order of statements. Otherwise, we use a TL_READ lock to + // improve performance. + tl->lock_type= using_update_log ? TL_READ_NO_INSERT : TL_READ; tl->updating= 0; wants= SELECT_ACL; } |