I am using SUMIFS with references to another workbook, which only works when that workbook is open. Based on this article, I tried to rewrite the SUMIFS to a combination of SUM, IF and AND to avoid this issue, however I can’t get it to work.
Here a sample table:
| A | B | C |
1 | x | m | 3 |
2 | x | m | 4 |
3 | y | n | 6 |
4 | y | n | 7 |
My original formula returns 7:
=SUMIFS(C:C;A:A;"a";B:B;"m")
The following formula with only one criteria works and returns 7:
=SUM(IF(A:A="x",C:C,0))
However, if I try to add a second criteria with AND (as recommended in the article), it always returns 0.
=SUM(IF(AND(A:A="a";B:B="m");C:C;0))
Any idea of how I could get this to work (without using the flawed SUMIFS)?
>Solution :
A multiply will help something like this
=SUM(IF((A:A="a")*(B:B="m");C:C;0))
AND function does the evaluation for all the items in the result.