Counting number of computers with specific custom property result

(imported topic written by jasonpap200291)

Hi,

I’ve searched and cross-searched and reversed-searched - just can’t find what I’m looking for. Should be easy, which is what is driving me. But, I’ve given up and now will ask the teachers for the answer :frowning:

Q1: I want to add up the number of computers that have a specific response to a custom property. To be specific, I have created a simple custom property that checks if Microsoft Exchange has been installed. The result of the property is “yes” or “no”. In my web reports I would like to add up and present the number of servers that have Exchange installed (i.e. returns the value “yes”).

Here is the latest installment that simply counts the total number of computers since it isn’t distinguishing whether the result is “yes” or “no” (“Microsoft Exchange 2003/2007” is the name of my custom property):

Number of Exchange Servers

<?Relevance ( td of (number of computers of results (bes property "Microsoft Exchange 2003/2007", bes computers) as string) )?>

I feel it should have “as lowercase contains “yes”” or something.

Q2: Similar to above I think. How would I add up the number of computers that have a custom bes property greater than 1? In other words, if a bes property for a specific server is 1 or greater, than add it. To be specific, I want to add up the number of servers that have detected a virus in the last 24 hours.

Q3: Is there a good resource with examples for custom web reports? I like to read, and I hate asking dumb questions. Standard documentation doesn’t seem to fill in all the holes and I thought I’d ask. I’m thinking www.pimpmybes.com is the only option. :slight_smile:

Thanks in advance, as always.

-Jason

(imported comment written by jasonpap200291)

Ok, I think I found the answer to Q1. Naturally as soon as I post the question. doh!

Something like this?

td of (number of computers whose( value of result (bes property “Microsoft Exchange 2003/2007”,it) contains “Yes”) of it as string)

Q2 still eludes me however (assuming the above is correct, need to try it).

Thanks in advance,

Jason

(imported comment written by Lee Wei)

Hi Jason,

There are always different ways to write the statements. So here are 2 examples.

For Q1:

number of results from (bes computers) whose (value of it as lowercase = 
"yes") of bes property 
"Microsoft Exchange 2003/2007"

For Q2:

sum of ((values of results from (bes computers) whose (value of it as integer > 1) of bes property 
"Your Property") as integer)

Lee Wei

(imported comment written by jasonpap200291)

Thanks Lee. Works perfectly of course.

Much obliged,

Jason