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

Custom Alert

Jump to solution

Hi all,

I am fulfilling a request for a customer and I wanted to present an alert box in their page, but I am only seeing an option to have the full list of alerts. I did not find a way to trim the alerts down to only the alerts pertaining to this customers request. I have not taken a look at the possibility of making a report yet, but I am going to take a look at that as well.

Just wanted to throw this out there to see if anyone else had this issue/solution.

Thanks as always for the communication/help!

0 Kudos
1 Solution
Level 13

HI..

You can probably do this so many different ways with view limitations, sql and Swql.. because i like the query route ill show you would you could do, or what i would do in this scenario

First create an Alert custom property, i have one called 'ResponsibleTeam' then select the alert you want your customer to see, update that alert custom property with your customer name i have 'HR' as an example

pastedImage_1.png

Create a 'Custom Query' widgit paste the following and update the WHERE AP.ResponsibleTeam = 'HR'

SELECT ' ' as [Severity], AC.Name AS AlertName, ao.EntityCaption AS Object, ao.EntityDetailsUrl AS [_LinkFor_Object],aa.TriggeredDateTime AS Time,

Case WHEN ac.Severity = '0' THEN ('/Orion/images/ActiveAlerts/InformationalAlert.png')

WHEN ac.Severity = '1' THEN ('/Orion/images/ActiveAlerts/Warning.png')

WHEN ac.Severity = '2' THEN  ('/Orion/images/ActiveAlerts/Critical.png')

WHEN ac.Severity = '3' THEN  ('/Orion/images/ActiveAlerts/Serious.png')

WHEN ac.Severity = '4' THEN ('/Orion/images/ActiveAlerts/Notice.png')

End as [_IconFor_Severity]

FROM Orion.AlertActive AA

INNER JOIN Orion.AlertObjects AO ON AA.AlertObjectID = AO.AlertObjectID

INNER JOIN Orion.AlertConfigurations AC ON AC.AlertID = AO.AlertID

INNER JOIN Orion.AlertConfigurationsCustomProperties AP ON AP.AlertID = AC.AlertID

WHERE AP.ResponsibleTeam = 'HR'

ORDER BY AA.TriggeredDateTime desc

output:

pastedImage_0.png

View solution in original post

3 Replies
Level 13

HI..

You can probably do this so many different ways with view limitations, sql and Swql.. because i like the query route ill show you would you could do, or what i would do in this scenario

First create an Alert custom property, i have one called 'ResponsibleTeam' then select the alert you want your customer to see, update that alert custom property with your customer name i have 'HR' as an example

pastedImage_1.png

Create a 'Custom Query' widgit paste the following and update the WHERE AP.ResponsibleTeam = 'HR'

SELECT ' ' as [Severity], AC.Name AS AlertName, ao.EntityCaption AS Object, ao.EntityDetailsUrl AS [_LinkFor_Object],aa.TriggeredDateTime AS Time,

Case WHEN ac.Severity = '0' THEN ('/Orion/images/ActiveAlerts/InformationalAlert.png')

WHEN ac.Severity = '1' THEN ('/Orion/images/ActiveAlerts/Warning.png')

WHEN ac.Severity = '2' THEN  ('/Orion/images/ActiveAlerts/Critical.png')

WHEN ac.Severity = '3' THEN  ('/Orion/images/ActiveAlerts/Serious.png')

WHEN ac.Severity = '4' THEN ('/Orion/images/ActiveAlerts/Notice.png')

End as [_IconFor_Severity]

FROM Orion.AlertActive AA

INNER JOIN Orion.AlertObjects AO ON AA.AlertObjectID = AO.AlertObjectID

INNER JOIN Orion.AlertConfigurations AC ON AC.AlertID = AO.AlertID

INNER JOIN Orion.AlertConfigurationsCustomProperties AP ON AP.AlertID = AC.AlertID

WHERE AP.ResponsibleTeam = 'HR'

ORDER BY AA.TriggeredDateTime desc

output:

pastedImage_0.png

View solution in original post

thank you sir. apologies for the late response... been really busy. i tried the query, but had some issues with it. i will have to tweak with it more, but the view limitations is a great alternative as well. Thank you all for the help

In addition to this you could limit the view itself via View Limitations so they'll only see nodes/alerts/etc relating to their silo:

Success Center