SUMIF


J

JBoyer

Hi,
I am trying to find the sum of a column based on values from another column.
For example, If I am inserting a sumif function in b5, and finding the sum of
values b1:b4. I want the function to only sum the values in b1:b4 who have a
corresponding d cell that is not blank. For instance, if b1=1, b2=2, b3=3,
b4=4 and d1=5, d2 is blank, d3=4, d4 is blank. I only want the add b1 and b3
= 4.
 
Ad

Advertisements

D

Dave Peterson

=sumif(d1:d4,"<>",b1:b4)
Hi,
I am trying to find the sum of a column based on values from another column.
For example, If I am inserting a sumif function in b5, and finding the sum of
values b1:b4. I want the function to only sum the values in b1:b4 who have a
corresponding d cell that is not blank. For instance, if b1=1, b2=2, b3=3,
b4=4 and d1=5, d2 is blank, d3=4, d4 is blank. I only want the add b1 and b3
= 4.
 
J

JBoyer

When I tried this function it displayed a value of 0. Any other suggestions
would be appreciated.
 
D

Dave Peterson

And if you just use =sum(b1:b4), what do you get?

If that's 0 (and it shouldn't be), then maybe your "numbers" are text. Format
the cells as General and then retype those entries and try both formulas.

Or maybe d1:d4 are all empty???
 
Ad

Advertisements

J

JBoyer

Sorry for the confusion, I knew the formula should work but I didn't
understand why it wouldn't. But, yes the cells were formated as general and I
had to change them to number format.

Again, thanks for the initial help and the response to my stupidity.
 

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