Re: Locking problem with triggers
We are seeing something similar. This is not a full test case, but an illustration derived from our code:
update `a` join `b` on `a`.`id`=`b`.`aid` set `b`.`something`="hello" where `a`.`acctid`=1234 and `b`.`something`="there";
There is an update trigger on `b` that checks for some columns being changed (not including `something`). In many cases, the result set impacted by the above update can be tens of thousands of records. Tables `a` and `b` are innodb, and have millions of rows each.
Once the trigger starts, queries like:
update `a` set `a`.`foo`=27;
lock, *even if they were running before the above update starts*. Effectively, big retroactive table locks get placed on both `a` and `b`.
Adding an index on `b` for `something` didn't help.
Any ideas?
Subject
Views
Written By
Posted
3203
May 25, 2006 12:48PM
Re: Locking problem with triggers
2107
May 29, 2006 03:31PM
1916
May 31, 2006 12:19PM
1935
June 02, 2006 06:29AM
1944
July 14, 2006 03:17AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.