SUMPRODUCT with multiple OR

WildWill

Board Regular
Joined
Sep 10, 2009
Messages
92
Hi

I am trying to modify this SUMPRODUCT formula so that the last component:*('Staffing Data'!$AB$8:$AB$9082={"Active - Off Site","Active - Site Based"}) will search for any of three conditions and not just two, as indicated here. I have tried adding the third condition but it does not seem to work. How would I modify this to count occurences of "Active - Off Site", "Active - On Site" OR "Active - Training})? Here is the full sum:


=SUMPRODUCT(('Staffing Data'!$S$8:$S$9082="Unskilled - Defined Decision-making")*('Staffing Data'!$K$8:$K$9082="Male")*('Staffing Data'!$L$8:$L$9082="Black")*('Staffing Data'!$AB$8:$AB$9082={"Active - Off Site","Active - Site Based"}))
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Try this:

Code:
=SUMPRODUCT(('Staffing Data'!$S$8:$S$9082="Unskilled - Defined Decision-making")
           *('Staffing Data'!$K$8:$K$9082="Male")
           *('Staffing Data'!$L$8:$L$9082="Black")
           *('Staffing Data'!$AB$8:$AB$9082={"Active - Off Site","Active - Site Based","Active - Training}))
 
Upvote 0
it worked for me...
=SUMPRODUCT(('Staffing Data'!$S$8:$S$9082="Unskilled - Defined Decision-making")*('Staffing Data'!$K$8:$K$9082="Male")*('Staffing Data'!$L$8:$L$9082="Black")*('Staffing Data'!$AB$8:$AB$9082={"Active - Off Site","Active - Site Based","Active - Training"}))
 
Upvote 0
Hi

I am trying to modify this SUMPRODUCT formula so that the last component:*('Staffing Data'!$AB$8:$AB$9082={"Active - Off Site","Active - Site Based"}) will search for any of three conditions and not just two, as indicated here. I have tried adding the third condition but it does not seem to work. How would I modify this to count occurences of "Active - Off Site", "Active - On Site" OR "Active - Training})? Here is the full sum:


=SUMPRODUCT(('Staffing Data'!$S$8:$S$9082="Unskilled - Defined Decision-making")*('Staffing Data'!$K$8:$K$9082="Male")*('Staffing Data'!$L$8:$L$9082="Black")*('Staffing Data'!$AB$8:$AB$9082={"Active - Off Site","Active - Site Based"}))
It'd be better if you used cells to hold the criteria.

A1 = Unskilled - Defined Decision-making
B1 = Male
C1 = Black
D1 = Active - Off Site
D2 = Active - Site Based
D3 = Active - Training

Then:

=SUMPRODUCT(--('Staffing Data'!$S$8:$S$9082=A1),--('Staffing Data'!$K$8:$K$9082=B1),--('Staffing Data'!$L$8:$L$9082=C1),--(ISNUMBER(MATCH('Staffing Data'!$AB$8:$AB$9082,D1:D3,0))))
 
Upvote 0

Forum statistics

Threads
1,224,585
Messages
6,179,700
Members
452,938
Latest member
babeneker

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top