This discussion has been locked. The information referenced herein may be inaccurate due to age, software updates, or external references.
You can no longer post new replies to this discussion. If you have a similar question you can start a new discussion in this forum.

SWQL Route Flapping Help

I am creating a Custom SWQL query for Route flapping. I found a SQL report that will work, but I cannot get my query to work in SWQL. I am trying to show the number of route flaps in the past hour. Here is the query I have so far:

Select TOP 50

     N.NODEID,

     DATEADD(hour,-1,GETDATE()) as "one hour ago",

     N.CAPTION AS "DEVICE"

     RF.ROUTEDESTINATION AS "ROUTE DESTINATION",

     COUNT(1) AS "TIMES FLAPPED"

FROM

     NPM_ROUTINGTABLE_FLAP RF

JOIN

     NODES N ON N.NODEID = RF.NODEID

WHERE datetime > DATEADD(hour,-1,GETDATE())

GROUP BY N.CAPTION, RF.ROUTEDESTINATION, N.NODEID

ORDER BY "TIMES FLAPPED" DESC

Any help would be greatly appreciated.