These pages cover SQL Monitor 10, which is not the latest version. Help for other versions is also available.
Ignoring additional waits
Published 17 August 2020
SQL Monitor ignores a number of waits by default. It may be necessary or desirable to ignore additional waits.
Step-by-step guide
Ignorable waits can be added to the table settings.KeyValuePairs
. It is recommended that you verify the insert is working as desired before modifying the contents of this table. This guide makes the assumption that you will be verifying the data in Step 1 before committing the data in Step 2.
In this step we verify that the wait to be inserted is correct. As an example, the wait
PWAIT_DIRECTLOGCONSUMER_GETNEXT
is being ignored:BEGIN TRANSACTION;
DECLARE @IgnoreWait NVARCHAR(128);
-- Replace the value below with the wait you wish to ignore, surrounded by double quotesSET @IgnoreWait = '"PWAIT_DIRECTLOGCONSUMER_GETNEXT"';
SELECT KeyValue
FROM settings.KeyValuePairs
WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore';
UPDATE settings.KeyValuePairs
SET KeyValue = @IgnoreWait + ',' + KeyValue
WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore';
SELECT KeyValue
FROM settings.KeyValuePairs
WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore';
ROLLBACK TRANSACTION;
- Verify the output of the SELECT statements in Step 1. You should see output similar to the following:
Note that the newly-added wait will appear at the beginning of the list of ignorable waits. - Once you are happy with the output of Step 1, you can update the contents of the table as follows:
DECLARE @IgnoreWait NVARCHAR(128);
SET @IgnoreWait = '"PWAIT_DIRECTLOGCONSUMER_GETNEXT"';
UPDATE settings.KeyValuePairs
SET KeyValue = @IgnoreWait + ',' + KeyValue
WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore'
;
settings.KeyValuePairs
are maintained after an update to SQL Monitor.