| Goal | Find UPDATE triggers where updated columns are not specified. These triggers could be executed too often because unneeded executions are not prevented. |
|---|---|
| Notes | The query finds UPDATE triggers where the updated columns have not been specified. The query excludes triggers that according to the WHEN clause seem to react to a data change in any column. |
| Type | Problem detection Each row in the result could represent a flaw in the design |
| Reliability | Low Many false-positive results |
| License | MIT (opens in new tab) |
| Fixing Suggestion | Do not let the system to do extra work. Ensure that trigger procedures are executed only if there is a real need of that. Specify a list of columns where updating data will cause execution of the trigger. |
| Data Source | INFORMATION_SCHEMA only |
| SQL Query |
|
Collections
This query belongs to the following collections:
Find problems automatically
Queries, that results point to problems in the database. Each query in the collection produces an initial assessment. However, a human reviewer has the final say as to whether there is a problem or not .
| Name | Description |
|---|---|
| Find problems automatically | Queries, that results point to problems in the database. Each query in the collection produces an initial assessment. However, a human reviewer has the final say as to whether there is a problem or not . |
Categories
This query is classified under the following categories:
Performance
Queries of this category provide information about indexes in a database.
Triggers and rules
Queries of this category provide information about triggers and rules in a database.
| Name | Description |
|---|---|
| Performance | Queries of this category provide information about indexes in a database. |
| Triggers and rules | Queries of this category provide information about triggers and rules in a database. |