This discussion has been locked. The information referenced herein may be inaccurate due to age, software updates, or external references.
You can no longer post new replies to this discussion. If you have a similar question you can start a new discussion in this forum.

Custom chart with SWQL not pulling column names

I'm am building a custom chart to display historical data from some custom pollers. I have my SWQL query built using SWQL studio and it returns all the data I'm looking for. When I add the query to the datasource and click preview results, it shows me the data I expect. However, when I go to add a dataseries for the Y axis, none of the columns show up. It doesn't give me anything to select. But when I edit the data grouping and legend shows info, the columns all show up as expected. Its only when I try to add a data series that none of the columns show up. I've done quite a few custom charts that look very similar and use similar queries and haven't had this trouble. I've pasted the SWQL below. Any ideas? Thanks!

SELECT TOP 1500 NodeID, CustomPollerAssignmentID, Description, DetailsUrl, N.Node.DisplayName as NodeName, N.CustomPollerStatistics.Status, N.CustomPollerStatistics.DateTime
FROM Orion.NPM.CustomPollerAssignmentOnNode AS N WHERE CustomPollerAssignmentID = '224d7964-283f-43d1-afdb-d1d4b7b5345c' OR CustomPollerAssignmentID = 'b3139923-84f0-41ed-be53-ff580631b068' OR CustomPollerAssignmentID = 'f3bd0131-90d8-4a6e-bcfc-4864f9f054f7' OR CustomPollerAssignmentID = 'cb36c270-f361-4567-9f48-cf07f3b113cd' OR CustomPollerAssignmentID = '7cd49e2f-662d-4d8a-91a7-5fc98b6ef61a' OR CustomPollerAssignmentID = '795259a1-bf0e-47da-bab3-7baf110162c9' ORDER BY N.CustomPollerStatistics.DateTime DESC

  • The charts always need 3 elements, one must be a number to be charted out, then we need a time series value, and lastly a label of some sort for the group by/legend.

    None of the fields you listed are actually a number. N.CustomPollerStatistics.Status is typed in the DB as a string, despite the fact that maybe for your particular poller it is returning a number it could be anything depending on the OID being polled. Since SWQL doesnt have an explicit cast() function the trick I've used for forcing a conversion is to select 1.0*N.CustomPollerStatistics.Status as [Statistic] and I'd expect then it will show up.