Skip to main content
Announcements
July 15, NEW Customer Portal: Initial launch will improve how you submit Support Cases. IMPORTANT DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
accrewchief
Contributor II
Contributor II

Count

Hello, I have a column with a rather large script that the end result gives me a a displayed "yes" and "no". I want to count the columns total "yes" and total "no" so i can make a simple percentage display of "yes".  Again the script to get the yes and no is rather large so i do not want to include that script in my count if possible. I just want a sum all the yes and no in that one column based on the display of "yes" and "no". Is this possible?

7 Replies
sunny_talwar

May be just this

Count yes

 

Count({<FieldName = {'yes'}>} FieldName)

 

Count no

 

Count({<FieldName = {'no'}>} FieldName)

 

 

accrewchief
Contributor II
Contributor II
Author

It almost works, its only counting one(1) and not summing them all up

sunny_talwar

Is this field coming from table not joined to your main table?

accrewchief
Contributor II
Contributor II
Author

No its from the main table or actually the only table i have. 

sunny_talwar

Couple of things to check

1) Do you have more than 1 rows in your table?

2) If you do, make sure you DO NOT do DISTINCT Count.... You need a simple count here...

accrewchief
Contributor II
Contributor II
Author

yes there are several rows in the column, and again scripting to get the results of yes and no is lengthy. But basically i have a 100 rows and 75 are given the results (and displayed) "yes" and  25 are "No" I want to have a percentage bar up top that says 75% yes so thats why i am trying to do the count., 

sunny_talwar

This should work in that case

Count({<FieldName = {'yes'}>} FieldName)/Count(FieldName)