Sum with a Twist Q

S

Seanie

How could I add up all values in two ranges where the value in a
separate range equals one of 2 values?

As an example

I wish to add all values in Ranges H10:H22 IF the corresponding value
in J10:J22 is one of 333333 or 444444 or 1111111 or 2222222
+
All values in Ranges H28:H40 IF the corresponding value in J28:J40 is
one of 333333 or 444444 or 1111111 or 2222222 + etc etc

An alternative to above that might be neat is:-

Add all values in Ranges H10:H22 IF the corresponding value in J10:J22
is a continuous 6 or 7 digit value i.e. 333333 or 444444 or 1111111 or
2222222 + etc etc
 
M

Mike H

Hi,

You could do it with multiple sumifs with your criteria in a cell

=SUMIF(J10:J22,A1,H10:H22)+SUMIF(J10:J22,A2,H10:H22)


In this case the criteria are in A1 and A2

Mike
 
B

barry houdini

Hello Seanie,

You can use SUMIF like this

=SUM(SUMIF(J10:J22,{333333,444444},H10:H22))
 

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