SUMPRODUCT excluding multiple conditions

T

tmwilkin

I know how to work a sumproduct where you're trying to include multiple
values in an array, but how do you exclude multiple values.

Below is the formula I am currently using:
=SUMPRODUCT(--($G$2:$G$8000=J8),--($E$2:$E$8000<>"NJ"),--($F$2:$F$8000<>"FL"),--($D$2:$D$8000))

I need the ($F$2:$F$8000<>"FL") to also be <> to "NJ" too.

Any help would be greatly appreciated. Thanks!
 
M

Mike H

try

=SUMPRODUCT(($G$2:$G$800=J8)*($E$2:$E$800<>"NJ")*($F$2:$F$800<>"FL")*($F$2:$F$800<>"NJ")*($D$2:$D$800))

Mike
 
P

Peo Sjoblom

Maybe this

=SUMPRODUCT(--($G$2:$G$8000=J8),--($E$2:$E$8000<>"NJ"),--($F$2:$F$8000<>"FL"),--($F$2:$F$8000<>"NJ"),$D$2:$D$8000)

If you are totaling numbers in D2:D80000 then you don't need the unary
minuses for the last part


--


Regards,


Peo Sjoblom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top