1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

- set 'updating' in both tables list if we have two of them (because of subquery) (BUG#13236)

- fixed test


mysql-test/r/rpl_multi_update2.result:
  fixed setting/reseting environment
  multi-update with subquery added
mysql-test/t/rpl_multi_update2.test:
  fixed setting/reseting environment
  multi-update with subquery added
sql/sql_update.cc:
  set 'updating' in both tables list if we have two of them (because of subquery)
This commit is contained in:
unknown
2005-10-14 00:02:38 +03:00
parent c8067ec848
commit 0069549021
3 changed files with 46 additions and 2 deletions

View File

@ -4,6 +4,7 @@ reset master;
reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave;
drop table if exists t1,t2;
CREATE TABLE t1 (
a int unsigned not null auto_increment primary key,
b int unsigned
@ -40,3 +41,15 @@ SELECT * FROM t2 ORDER BY a;
a b
1 0
2 1
drop table t1,t2;
reset master;
CREATE TABLE t1 ( a INT );
INSERT INTO t1 VALUES (0);
UPDATE t1, (SELECT 3 as b) AS x SET t1.a = x.b;
select * from t1;
a
3
select * from t1;
a
3
drop table t1;