what is the swql query to fetch the node metrics with in a specified dates. Can we change the dateformat while storing the metrics in the solarwinds db. right now it is yyyy-MM-dd HH:MM:ss.SSS format
what is the swql query to fetch the node metrics with in a specified dates. Can we change the dateformat while storing the metrics in the solarwinds db. right now it is yyyy-MM-dd HH:MM:ss.SSS format
The date functions can be found on SolarWinds wiki for the OrionSDK here:
SWQL Functions · solarwinds/OrionSDK Wiki · GitHub
An example for interface traffic over the last 60 minutes would be this:
SELECT n.Caption, i.Caption, it.[DateTime], it.Averagebps
FROM Orion.Nodes n
JOIN Orion.NPM.Interfaces i ON n.NodeID = i.NodeID
JOIN Orion.NPM.InterfaceTraffic it ON i.InterfaceID = it.InterfaceID
WHERE MINUTEDIFF(it.[DateTime], GETDATE()) <= 60
--
Steven W. Klassen
Programmer Analyst @ Loop1 Systems
SolarWinds solutions are rooted in our deep connection to our user base in the THWACK® online community. More than 195,000 members are here to solve problems, share technology and best practices, and directly contribute to our product development process.