Hi Everyone,
Actually, I'm new to SolarWinds and SQL server 2008 commands. Currently, I use NPM 10.6. And, in my work environment, SolarWinds runs on Microsoft SQL server 2008.
Although, I stand corrected but I observed that the Orion Report Writer cannot capture historical percentage utilization of an interface, whether transmit or receive; instead, it can only capture current utilization. Please, I need help if capturing the historical one is possible.
Also, I have another challenge. I want to be able to generate reports concerning node and/or interface availability between, say 6:00am to 8:00pm each weekday only, that is, from Mondays to Fridays.
I tried doing it using the Orion Report Writer but all I can get under the Time Frame box is Last 7 days, Last Month, etc. Please how do I go about it? Find below the code I wrote while trying to generate a new report and using the Advanced SQL report type.
DECLARE @StartDate DateTime
DECLARE @EndDate DateTime
SET @StartDate = '2014-01-20'
SET @EndDate = '2014-01-24'
WHILE (@StartDate < @EndDate)
--- CASE (DATEPART(dw, @StartDate))
SELECT TOP 10000
Nodes.NodeID AS NodeID, Nodes.Caption AS NodeName, Nodes.Location AS Location, Interfaces.InterfaceName AS Interface_Name, AVG(Interfaces.InPercentUtil) AS Recv_Percent_Utilization, AVG(Interfaces.Inbps) AS Recv_bps, AVG(ResponseTime.Availability) AS AVERAGE_of_Availability, MIN(ResponseTime.MinResponseTime) AS MIN_of_Minimum_Response_Time, AVG(ResponseTime.AvgResponseTime) AS AVERAGE_of_Average_Response_Time, MAX(ResponseTime.MaxResponseTime) AS MAX_of_Peak_Response_Time
FROM
Nodes INNER JOIN Interfaces ON (Nodes.NodeID = Interfaces.NodeID) INNER JOIN ResponseTime ON (Nodes.NodeID = ResponseTime.NodeID)
WHERE
(
(DateTime BETWEEN @StartDate AND @EndDate) AND (Nodes.Caption LIKE '%AIDOS%') AND ((Interfaces.InterfaceName LIKE '%Tunnel%%') OR
(Interfaces.InterfaceName LIKE '%Gigabitethernet%0/2%%'))
)
GROUP BY Nodes.NodeID, Nodes.Caption, Nodes.Location, Interfaces.InterfaceName
ORDER BY Nodes.NodeID, DateTime ASC
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Honestly, the code ran but I do not think it's actually correct. Please I need help. Many thanks as you contribute to help me work better.