stupideye
stupideye

Reputation: 27

Adding multiple SUMIF's

I'm trying to add 5 columns (5 different sheets), only taking numbers that are greater than 0 in a specific column. I also have another cell which will be used to do the same but with numbers less than 0. My issue is that my formula gives me a really wacky number which isn't even close to what I'm looking for.

Here's what I have, it should be pretty self explanatory on it's own, but if more information is needed let me know:

=SUMIF(Monday!E24:E38,">0")+SUMIF(Tuesday!E24:E38,">0")+SUMIF(Wednesday!E24:E38,">0")+SUMIF(Thursday!E24:E38,">0")+SUMIF(Friday!E24:E38,">0")

This is also pretty messy as it is, so any suggestions on making something a bit cleaner would be helpful too.

Thank you in advance to anyone that can help!

Upvotes: 1

Views: 71

Answers (1)

Rob Sedgwick
Rob Sedgwick

Reputation: 4514

The problem is you cannot use SUMIF across multiple sheets. The solution is to use a combination of SUMIF, INDIRECT and SUMPRODUCT as shown here:

https://exceljet.net/formula/3d-sumif-for-multiple-worksheets

https://exceljet.net/sites/default/files/styles/function_screen/public/images/formulas/3D%20SUMIF%20for%20multiple%20sheets.png?itok=YWNYB5jC

Upvotes: 1

Related Questions