cancel
Showing results for 
Search instead for 
Did you mean: 
Create Post
Level 7

Alert on 3 hi of last 100 samples

Jump to solution

I'm tring to configure an alert the will trigger is 3 of the last 100 samples exceeds a limit.

Specifically, I'm looking at the Windows counter "% Committed Bytes in Use" and want an alert when any 3 of the last 100 polls exceeds 50%.

Thanks,

Tags (1)
0 Kudos
1 Solution

You are right there is one more thing missing. Sub select for selecting ID's should be ordered by ID descending. So, it will take last ID's as a top ones. Therefore, selecting TOP 3 from last 100 or TOP 3 from all is the same thing.

The right syntax of the sub-select is:

SELECT  TOP 3 [ID] FROM

[dbo].[APM_ComponentStatus_Detail] [CSD2]

WHERE [CSD2].[ComponentID] = [CSD1].[ComponentID]

ORDER BY [ID] DESC

 

Regards

View solution in original post

0 Kudos
3 Replies

Hello,
You can do this with advanced SQL alert where you select top three of last statistic. Here is how the setup of trigger and reset condition could look like. You will need to specify the exact value of threshold, I used 50 as a sample value.

 

 

 

Regards,

Thanks for the reply,

I see where you are selecting the top 3 statistics from the sample but where are you selecting the last 100.  My problem is I'm trying to get the top 3 from the last 100 samples and I'm not sure this quite gets it.  It's very close and I appreciate your effort in helping me.

Thanks,

Eric

0 Kudos

You are right there is one more thing missing. Sub select for selecting ID's should be ordered by ID descending. So, it will take last ID's as a top ones. Therefore, selecting TOP 3 from last 100 or TOP 3 from all is the same thing.

The right syntax of the sub-select is:

SELECT  TOP 3 [ID] FROM

[dbo].[APM_ComponentStatus_Detail] [CSD2]

WHERE [CSD2].[ComponentID] = [CSD1].[ComponentID]

ORDER BY [ID] DESC

 

Regards

View solution in original post

0 Kudos