Bug #23771 | AFTER UPDATE trigger not invoked when there are no changes of the data | ||
---|---|---|---|
Submitted: | 30 Oct 2006 14:04 | Modified: | 15 Mar 2008 9:37 |
Reporter: | Georgi Kodinov | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Stored Routines | Severity: | S3 (Non-critical) |
Version: | 5.0.27/5.1BK | OS: | Linux (Suse 10.0 32-bit) |
Assigned to: | Davi Arnaut | CPU Architecture: | Any |
[30 Oct 2006 14:04]
Georgi Kodinov
[30 Oct 2006 15:58]
MySQL Verification Team
Thank you for the bug report.
[12 Feb 2008 11:44]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/42102 ChangeSet@1.2546, 2008-02-12 09:44:27-02:00, davi@mysql.com +3 -0 Bug#23771 AFTER UPDATE trigger not invoked when there are no changes of the data The problem is that AFTER UPDATE triggers will fire only if the new data is different from the old data on the row. The trigger should fire regardless of whether there are changes to the data. The solution is to fire the trigger on UPDATE even if there are no changes to the value (because the value is the same).
[19 Feb 2008 13:42]
Davi Arnaut
Pushed in 5.1-runtime
[3 Mar 2008 18:18]
Bugs System
Pushed into 5.1.24-rc
[3 Mar 2008 18:18]
Bugs System
Pushed into 6.0.5-alpha
[15 Mar 2008 9:37]
Jon Stephens
Documented in the 5.1.24 and 6.0.5 changelogs as follows: An AFTER UPDATE trigger was not invoked when the UPDATE did not make any changes in the table. Now AFTER UPDATE triggers behave the same in this regard as do BEFORE UPDATE triggers, which are invoked whether the UPDATE makes any changes in the table or not. Also tagged as an important change in behaviour.
[30 Mar 2008 0:08]
Jon Stephens
Also documented fix for 5.1.23-ndb-6.3.11.