CASE will give me what I want but I am just curious if this has some special sentimentality to the devs beyond simply being the largest double precision floating point number.
1.79769313486232E+308 is essentially null expressed as a double (8 byte) integer in C#.
Ah
I only ask because to filter it out I had to covert that float value to varchar and not like '1.7976%' which must be a performance hit.
Sounds like you're trying to recreate this report -> Component_Monitor_Threshold_Value_Report_(with_nulls).OrionReport
Recreate it with SWQL -right now it's filtering based on template names but I need to use something closer to assignment. Until we have something better, , can you point me in the direction of where template tags are stored in SWQL?
Thanks,
Christian
To be exact it is Double.MaxValue (rather than NULL) which in conjunction with "Is greater than" operator defines threshold that can never be exceeded. It is used as "empty" threshold where we cannot override to NULL.
EDIT: Nevermind, figured it out. If you do:
ANOTHER EDIT (I enjoy talking to myself): It looks like they use both negative and positive versions of the number to denote NULL throughout the APM Threshold table. Great... I've changed the code yet again to this:
CASE WHEN (t.Critical > 1.797E+300 OR t.Critical < -1.797E-300) THEN NULL ELSE t.Critical
(This works in SWQL at least. Can't promise it'd work in SQL. You probably want to use aLterego's report in the OP for SQL.)
This works perfect. In the SQL of the Report aLterego links to they have -1.797E-300 which is a negative value, but in the tables they use positive values, so once I removed the negative sign at the beginning and changed the one in the middle to a plus sign and changed the operator from less than to greater than it worked perfect.
Did you ever get a SWQL version of this figured out? If I try and cast the Critical/Warning fields using TOSTRING() I get an error. I really don't want to use SQL, but I may have to for this...