Quantcast
Channel: THWACK: All Content - Orion SDK
Viewing all articles
Browse latest Browse all 2677

Simple Display of Multiple Counts

$
0
0

First of all, I'd like to thank the THWACK community for making me look like such a creative genius to this point.

 

My latest idea sounded oh so simple, but I've not been able to wrap my mind around it. I'm sure I must be missing something very simple.

 

I have a view that has been put together to display BGP neighbor issues in a variety of formats.

Now I want to add a very simple counter widget to the main NOC page that displays just 2 numbers:

  • The number of nodes having 1 or more BGP neighbor issues
  • The number of BGP neighbors that are not in the ESTABLISHED state

 

I have solved how to count the neighbors, but I cannot figure out how to count up the unique nodes.

 

SELECT
Count(ORN.NodeID) AS [Neighbors]
FROM Orion.Routing.Neighbors AS ORN    WHERE ORN.ProtocolID = 14    AND ORN.IsDeleted = 0    AND ORN.ProtocolOrionStatus != 1

 

This will provide me with a table with 1 column "Neighbors" and a count beneath it, but what I want is the number of unique nodes first then the number of neighbors.

NodesNeighbors
2599

 

There is a part of me that thinks this format would be better, though, in case I were to expand the things being counted later. Bonus Points for this option too:

ErrorCount
BGP Nodes25
BGP Neighbors99

 

Thanks in advance!

 


Viewing all articles
Browse latest Browse all 2677

Trending Articles



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