Red Gate forums :: View topic - Alert Settings Long Running Query Exclude RegEx
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Monitor 3
SQL Monitor 3 forum

Alert Settings Long Running Query Exclude RegEx

Search in SQL Monitor 3 forum
Post new topic   Reply to topic
Jump to:  
Author Message
wwalborn



Joined: 13 Mar 2014
Posts: 3
Location: United States

PostPosted: Thu Mar 13, 2014 2:36 pm    Post subject: Alert Settings Long Running Query Exclude RegEx Reply with quote

Using: Version: 3.5.0.497

Here is an example email content for a long running query that I want to exclude (any SQLAgent jobs):

Process name: SQLAgent - TSQL JobStep (Job 0x1C32C6B680AD91468B8FB415ED990C70 : Step 6)

I have tried both of these and a few others, none of them seem to match and exclude, what am I missing?

Added to section
"Exclude queries with a SQL process name matching the following regular expressions:"

.*SQLAgent - TSQL JobStep .*

^SQLAgent.*


If are successfully filtering SQLAgent alerts, please share what is working for you. Thanks.
Back to top
View user's profile Send private message
Brian Donahue



Joined: 23 Aug 2004
Posts: 6649

PostPosted: Fri Mar 14, 2014 5:08 pm    Post subject: Reply with quote

Hello,

The last time this issue came up, it worked to put the whole string in square-brackets like this:
Quote:
[SQL Agent - TSQL JobStep]

Hopefully that does the trick.
Back to top
View user's profile Send private message
wwalborn



Joined: 13 Mar 2014
Posts: 3
Location: United States

PostPosted: Fri Mar 14, 2014 8:11 pm    Post subject: Reply with quote

Changed to use brackets, will see what happens this weekend. Thanks.
Back to top
View user's profile Send private message
wwalborn



Joined: 13 Mar 2014
Posts: 3
Location: United States

PostPosted: Mon Mar 17, 2014 3:02 pm    Post subject: Reply with quote

Well, that did not appear to work with simply brackets, I am going to try a shotgun approach and list all of the variations that seem logical to me:

[SQLAgent]
[SQLAgent]*
[SQLAgent].*
.*[SQLAgent].*
^SQLAgent.*
^SQLAgent.*\n
Back to top
View user's profile Send private message
Brian Donahue



Joined: 23 Aug 2004
Posts: 6649

PostPosted: Wed Mar 19, 2014 3:47 pm    Post subject: Reply with quote

I tried it using just the text and the query was blocked. Maybe you did not set the restriction at the right server? You can configure the alerts differently for different servers. Here is what I have set currently, which is blocking long-running query alerts for all servers:
Quote:
Exclude queries with a SQL process name matching the following regular expressions:
Red Gate Software - SQL Tools
SQLAgent - TSQL JobStep
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group