Checking multiple columns if true then return a value by doing this calculation

Ari_Ari
Ari_Ari ✭✭✭
edited 12/20/23 in Formulas and Functions

Hello,

I am having trouble with this formula. Your input is very much appreciated.

I have two columns I am checking if situation is true and if true, then i want to calculate the %complete against all tasks. Here are my columns

my current formula:

=IF(AND([Compliance Validation]@row = true, [% Complete]@row = "Complete"), COUNTIF([% Complete]:[% Complete], "Complete") / COUNT(Standard:Standard), 0)

Output I receive is a value of 20.69% which is not entirely correct.

Because the ask is to compute overall %complete if the Compliance Validation column is checked AND %Complete column is marked Complete but looks like the formula is only checking %Complete column for Complete and dismissing if the check box is checked also. Formula should not add the rows that are not checked into calculating overall % complete of the tasks (standard).

I tested by unchecking the check boxes, and I still receive same value 20.69%. See below.

Appreciate any help on my formula.

Best Answer

  • DKazatsky2
    DKazatsky2 ✭✭✭✭✭✭
    Answer ✓

    Hi @Ari_Ari,

    See if this gets you what you are looking for.

    =IF(AND([Compliance Validation]@row = true, [% Complete]@row = "Complete"), COUNTIFS([% Complete]:[% Complete], "Complete", [Compliance Validation]:[Compliance Validation], true) / COUNT(Standard:Standard), 0)

    Hope this helps,

    Dave

Answers

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!