cancel
Showing results for 
Search instead for 
Did you mean: 
Create Post
Level 10

Moving data from rows to columns

Setting up several UnDP's to gather interface data. The poller config does not allow me to get all of the data from the top OID 1.3.6.1.4.1.9.2.2.1.1, so I have to create multiple pollers. The result is that all the data goes in a table that puts each poller output in a separate row, but all the data is under just one column. I need each poller's output to have a separate column so that I can join the data with the interfaces table.

SELECT AssignmentName, InterfaceID, Status
FROM Orion.NPM.CustomPollerStatusOnInterface

Returns this:

AssignmentName (poller)InterfaceIDStatus (polled values)
locIfInputQueueDrops on router1 Te 1/3856970
locIfInOverrun  on router1 Te 1/3856970
locIfReliab  on router1 Te 1/385697255
locIfOutputQueueDrops  on router1 Te 1/385697186

 

I need something like this:

InterfaceIDlocIfInputQueueDropslocIfInOverrunlocIfReliablocIfOutputQueueDrops
8569700255186

 

I can join it to the Orion.NPM.Interfaces table easily enough, but then I have extra rows of duplicated data:

InterfaceInterfaceIDInterfaceID1Status1Speed%in Util%Out Util
Te2/0/38569785697010Gbps11
Te2/0/3856978569718610Gbps11
Te2/0/3856978569725510Gbps11

 

How do I consolidate those rows into a single column and separate Status into separate columns?

0 Kudos
1 Reply
MVP
MVP