summaryrefslogtreecommitdiff
path: root/mysql-test/r/update.result
diff options
context:
space:
mode:
authorunknown <evgen@moonbone.local>2005-12-01 23:22:20 +0300
committerunknown <evgen@moonbone.local>2005-12-01 23:22:20 +0300
commit136c81732a36c3410c8a30aa64652b3c18679a0f (patch)
tree3c4c81ee2c0591a8486928fe1acc499756cec8e9 /mysql-test/r/update.result
parent2a1ae3a5e3cbc7bb076c91ba0f8b5e6242319b28 (diff)
downloadmariadb-git-136c81732a36c3410c8a30aa64652b3c18679a0f.tar.gz
Fix bug#15028 Multitable update returns different numbers of matched rows
depending on table order multi_update::send_data() was counting updates, not updated rows. Thus if one record have several updates it will be counted several times in 'rows matched' but updated only once. multi_update::send_data() now counts only unique rows. sql/sql_update.cc: Fix bug#15028 Multitable update returns different numbers of matched rows depending on table order multi_update::send_data() now counts only unique rows. mysql-test/t/update.test: Test case for bug#15028 Multitable update returns different numbers of matched rows depending on table order mysql-test/r/update.result: Test case for bug#15028 Multitable update returns different numbers of matched rows depending on table order
Diffstat (limited to 'mysql-test/r/update.result')
-rw-r--r--mysql-test/r/update.result13
1 files changed, 13 insertions, 0 deletions
diff --git a/mysql-test/r/update.result b/mysql-test/r/update.result
index 74c628f96c4..7854fd773a1 100644
--- a/mysql-test/r/update.result
+++ b/mysql-test/r/update.result
@@ -345,3 +345,16 @@ f1
2000-01-01
2002-02-02
drop table t1;
+create table t1 (f1 int);
+create table t2 (f2 int);
+insert into t1 values(1),(2);
+insert into t2 values(1),(1);
+update t1,t2 set f1=3,f2=3 where f1=f2 and f1=1;
+affected rows: 3
+info: Rows matched: 3 Changed: 3 Warnings: 0
+update t2 set f2=1;
+update t1 set f1=1 where f1=3;
+update t2,t1 set f1=3,f2=3 where f1=f2 and f1=1;
+affected rows: 3
+info: Rows matched: 3 Changed: 3 Warnings: 0
+drop table t1,t2;