codebender

Comments

  • TOUPPER and TOLOWER appears in the autocomplete for the SWQL Studio. It appears to be documented here: SWQL Functions · solarwinds/OrionSDK Wiki · GitHub However, it doesn't appear here: Use SolarWinds Query Language (SWQL) in the Orion Platform - SolarWinds Worldwide, LLC. Help and Support Do enhancement requests get…
  • That was a good idea, but I get the error: Attempted to access and element as a type incompatible with the array from this. SELECT IP , DNS , 0 + O1 AS I1 , 0 + O2 AS I2 , 0 + O3 AS I3 , 0 + O4 AS I4 FROM ( SELECT N.IPAddress AS IP , TOLOWER(N.DnsBackward) AS DNS ,…
  • I'm using PowerShell in several instances as well, but have cases where I need SWQL to perform string parsing tasks. The powershell implementation seems to expose much more functionality of the SDK than others.
  • A dozen different attempts to get the various Nuget packages. I'm working offline and have to transfer the .nuget packages. I could never get a compile. When I gave up, the WebRequestHandler was an unrecognized function/class. Update: I went back and reattempted getting the .nuget packages and got the code to compile. It…
  • Perhaps that functionality has been removed or I don't understand the suggested syntax. When I do the following, I get an error: Failed to compare two elements in the array. SELECT N.IPAddress AS IP , N.DnsBackward , 0 + ARRAYVALUEAT(SPLITSTRINGTOARRAY(REPLACE(IP,'.','|§|§|')),0) AS O1 , 0 +…
  • Thanks for the reply. (How did you create that nice code block?) I tried to make the question generic so I could understand what if any linkages exist between the base Orion functionality and IPAM. Adding the full join against the NPM table as you have decreases the number of items returned significantly. I suspect we…
  • I didn't realize that the specialized SQL implementation that I use most frequently is special in this way. Each consecutive alias can refer to the previous ones. It's extremely useful for building strings, calculations & etc and then reusing their results.
  • Thanks for the suggestion, did that here
  • Percent is a multi-character wild card that is documented Use SolarWinds Query Language (SWQL) in the Orion Platform - SolarWinds Worldwide, LLC. Help and Support. It appears that, although undocumented, underscore '_' works as a single character like other SQL syntax. The question was more general. It appears that the…
  • Underscore does appear to work as a single wild card.
  • I attempted to start with that code. I couldn't compile it (VS2015 or VS2017) due to an undefined WebRequestHandler entry. Subsequently read elsewhere a comment that led me to understand I wouldn't be able to modify custom properties using that kind of connection and should use the Net.Tcp like the PowerShell scripts.
  • I got a reply on Stack Overflow that the two tables are essentially unrelated and used for different purposes. Is there documentation that backs up the answer? sdk - Are there formal linkages between base Orion functionality and IPAM - Stack Overflow I've been starting to think they are unrelated, but for the purpose of…
  • A handful of months later and I have a method to sort by IP Address from combining the various suggestions: SELECT DisplayName , IPAddress , 0 + ToString(ARRAYVALUEAT(SPLITSTRINGTOARRAY(REPLACE(IPAddress,'.','|§|§|')),0)) AS O1 , 0 + ToString(ARRAYVALUEAT(SPLITSTRINGTOARRAY(REPLACE(IPAddress,'.','|§|§|')),1)) AS O2 , 0 +…
  • Found a way to break apart the octets, but don't see a way to convert them into integers for the ORDER BY ... SELECT N.IPAddress AS IP , N.DnsBackward , ARRAYVALUEAT(SPLITSTRINGTOARRAY(REPLACE(IP,'.','|§|§|')),0) AS O1 , ARRAYVALUEAT(SPLITSTRINGTOARRAY(REPLACE(IP,'.','|§|§|')),1) AS O2 ,…
  • Saw your post and found I can separate values if I replace a character in the target field. In my case the IP Address's '.' SELECT N.IPAddress AS IP , N.DnsBackward , ARRAYVALUEAT(SPLITSTRINGTOARRAY(REPLACE(IP,'.','|§|§|')),0) AS O1 , ARRAYVALUEAT(SPLITSTRINGTOARRAY(REPLACE(IP,'.','|§|§|')),1) AS O2 ,…