Property value return integer value for report

Hello,

I am trying to create a report for machines with Less than 15000MB disk space. I have the following relevance for my disk space property

if (exists true whose (if true then exists drive of system folder else false)) then ((free space of drive of system folder)/(1024 * 1024)) as integer else 0 

I was expecting the condition to have an option less than, greater than or equal to but instead it has the following:
image

Is there a way I can have webreports recognize the property as an integer?

Thank you.

@jan.castro There is a long standing feature request for this.
Your workaround would be to build a custom version of the property that added in an indicator.

Like this:

q: if (exists true whose (if true then exists drive of system folder else false)) then ((if it < (15000) then (it as string & " MB - Warning - Disk < 15,000 MB") else (it as string)) of (((free space of drive of system folder)/(1024 * 1024)) as integer)) else "0" 
A: 661483

Then in Web Reports you could filter for “contains Warning”

2 Likes

Hello Brolly33,

Thank you very much for this input. I will be using this for now while the feature isn’t available yet :slight_smile:

An approach we’ve use that aids reporting is a custom property that splits the free space into groups, eg <1GB, <5GB, <10GB etc so you can at least get some level of grouping. I’m sure there is a cleaner way of doing this but the relevance we use is

if (relative significance place 3 of ((((free space of drive of system folder as floating point) / 1024) / 1024) / 1024) < "1.00" as floating point) then "< 1Gb" else if (relative significance place 3 of ((((free space of drive of system folder as floating point) / 1024) / 1024) / 1024) < "2.50" as floating point) then "< 2.5Gb" else if (relative significance place 3 of ((((free space of drive of system folder as floating point) / 1024) / 1024) / 1024) < "5.00" as floating point) then "< 5Gb" else if (relative significance place 3 of ((((free space of drive of system folder as floating point) / 1024) / 1024) / 1024) < "10.00" as floating point) then "< 10Gb" else if (relative significance place 3 of ((((free space of drive of system folder as floating point) / 1024) / 1024) / 1024) < "20.00" as floating point) then "< 20Gb" else "> 20Gb"

2 Likes

A slightly cleaner and more efficient method

Q: ((if(it < 1) then ("<1GB") else ((if(it < 2) then ("<2GB") else ((if(it < 5) then ("<5GB") else ((if(it < 10) then ("<10GB") else ((if(it < 20) then ("<20GB") else ((if(it < 50) then ("<50GB") else (">50GB") of it)) of it)) of it)) of it)) of it)) of it)) of (free space of drive of system folder / (1024 * 1024 * 1024))
A: <20GB
T: 0.453 ms
I: singular string
3 Likes

Hello Rob,

Thank you for providing this relevance. This is very useful! :slight_smile: