18 Replies Latest reply on Jun 30, 2017 5:16 AM by anningm

    Custom SWQL Query for Nodes Down Showing Every Time Node Went Down

    bharris

      I'm trying to tweak our nodes down resource to add the date/time the system went down.  I'm trying to figure out why it is listing all the times the nodes have went down and not just the most recent. 

       

      Here is the query:

      SELECT

      NodeName AS [Node Name],

              '/Orion/images/StatusIcons/Small-' + StatusIcon AS [_IconFor_Node Name],

              DetailsUrl AS [_LinkFor_Node Name],

              DOWNEVENT.EVENTTIME AS [DOWN TIME],

        Nodes.CustomProperties.Alert_Team as [ALERT TEAM]

      FROM ORION.NODES NODES

      INNER JOIN ORION.EVENTS DOWNEVENT

      ON NODES.NODEID = DOWNEVENT.NETWORKNODE

      WHERE STATUS = 2

      ORDER BY NodeName

       

      I am getting the following:

      Capture-nodesdown.JPG

       

      For the P server I'd like to just have the most recent time it has been down and not came back up, 9/2/2014 in this case.  For S server, 8/27/2014. 

       

      Is this possible to filter those others out?