Quantcast
Channel: THWACK: All Content - Network Performance Monitor
Viewing all articles
Browse latest Browse all 21870

Retrieving NodeID from the URL to match in a Custom Table's SQL Statement

$
0
0

I have a custom query that I would like to display the results based on the node I am currently viewing. Not all of them at once. I am having trouble with the syntax. Any help would be great

 

The syntax in red is what I am having an issue with. I can't seem to dynamically get the NodeID from the URL

 

 

SELECT c.NodeID,c.SysName,c.CustomPollerID,c.CustomPollerAssignmentID,d.RawStatus,RowID

FROM [SolarWindsOrion].[dbo].[CustomPollerStatus] d

 

LEFT JOIN(

 

SELECT b.*,InterfaceName

FROM [SolarWindsOrion].[dbo].[Interfaces] c

 

LEFT JOIN(

 

Select a.*, b.CustomPollerID,b.CustomPollerAssignmentID

FROM [SolarWindsOrion].[dbo].[CustomPollerAssignment] b

 

LEFT JOIN(

 

SELECT NodeID,SysName

FROM [SolarWindsOrion].[dbo].[Nodes] a

Where Vendor = 'Accedian'

 

) a

ON b.NodeID = a.NodeID

Where b.CustomPollerID IN ('6A74556A-96F5-47EE-8B06-6C66E883FDE3','3D843627-92A1-4840-B5C4-9846F072CB12')

 

) b

ON b.NodeID = c.NodeID

Where b.NodeID IS NOT NULL

 

) c

ON c.CustomPollerAssignmentID = d.CustomPollerAssignmentID

Where c.NodeID IS NOT NULL AND RawStatus IS NOT NULL AND NodeID = Request.QueryString("NetObject")

 

Group by NodeID, SysName, CustomPollerID,c.CustomPollerAssignmentID, RawStatus,RowID

Order by c.CustomPollerID,c.CustomPollerAssignmentID,d.RawStatus,d.RowID


Viewing all articles
Browse latest Browse all 21870

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>