diff options
Diffstat (limited to 'mysql-test/r/trigger.result')
-rw-r--r-- | mysql-test/r/trigger.result | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/mysql-test/r/trigger.result b/mysql-test/r/trigger.result index 8b384dfdc4e..e7f5c41513b 100644 --- a/mysql-test/r/trigger.result +++ b/mysql-test/r/trigger.result @@ -2016,4 +2016,42 @@ i j 10 10 unlock tables; drop table t1; +drop table if exists t1, t2; +drop trigger if exists trg1; +drop trigger if exists trg2; +create table t1 (a int); +create table t2 (b int); +create trigger trg1 after update on t1 for each row set @a= @a+1; +create trigger trg2 after update on t2 for each row set @b= @b+1; +insert into t1 values (1), (2), (3); +insert into t2 values (1), (2), (3); +set @a= 0; +set @b= 0; +update t1, t2 set t1.a= t1.a, t2.b= t2.b; +select @a, @b; +@a @b +3 3 +update t1, t2 set t1.a= t2.b, t2.b= t1.a; +select @a, @b; +@a @b +6 6 +update t1 set a= a; +select @a, @b; +@a @b +9 6 +update t2 set b= b; +select @a, @b; +@a @b +9 9 +update t1 set a= 1; +select @a, @b; +@a @b +12 9 +update t2 set b= 1; +select @a, @b; +@a @b +12 12 +drop trigger trg1; +drop trigger trg2; +drop table t1, t2; End of 5.1 tests. |