Forum Discussion

TrenaMCF's avatar
TrenaMCF
Copper Contributor
Jun 06, 2023
Solved

Using a sum within IF formula

I'm adding a count of donations from multiple sheets that will be matched up to 175 donations. I'm using IF to say: if the total # of donations from each sheet < 176, return the total donation count from each sheet, otherwise return 175. Here's what I entered, that's not working (edited for brevity), cell I8 in each sheet counts the # of donations on that sheet:
=IF(Sheet1!I8+Sheet2!I8+Sheet3!I8)<175,(Sheet1!I8+Sheet2!I8+Sheet3!I8),175
It returns the full text of my formula in the cell. Am I missing ( ) or is the syntax off?

  • TrenaMCF 

    =IF(Sheet1!I8+Sheet2!I8+Sheet3!I8<175,Sheet1!I8+Sheet2!I8+Sheet3!I8,175)

    This works in my sheet.

     

    =MIN(Sheet1!I8+Sheet2!I8+Sheet3!I8,175)

    An alternative could be this formula.

  • TrenaMCF 

    =IF(Sheet1!I8+Sheet2!I8+Sheet3!I8<175,Sheet1!I8+Sheet2!I8+Sheet3!I8,175)

    This works in my sheet.

     

    =MIN(Sheet1!I8+Sheet2!I8+Sheet3!I8,175)

    An alternative could be this formula.

    • TrenaMCF's avatar
      TrenaMCF
      Copper Contributor
      OliverScheurich, thank you that worked! I guess I didn't need the extra ( ). And thanks for sharing =min, haven't tried that one before. Appreciate your help.

Resources