Sumif Function

G

Guest

Hello,

I need help on a Sumif Function:
I need to Sumif the values in column F if and only if column B has "6" and
column C has "F"
Here's an example:

A B C D E F
54 6 M Q SptAcc 45
75 6 M E Escada 13
1 6 F 1 MEscada 761
9 6 F E Escada 20,091
9 6 F H Accessory 335
 
P

Portuga

Jeff said:
Hello,

I need help on a Sumif Function:
I need to Sumif the values in column F if and only if column B has "6"
and
column C has "F"
Here's an example:

A B C D E F
54 6 M Q SptAcc 45
75 6 M E Escada 13
1 6 F 1 MEscada 761
9 6 F E Escada 20,091
9 6 F H Accessory 335

Considering your sample starts on A1:

Put on cel G1 the following formula:
=IF(B1=6,F1,0)

Column G will now display values only when column B is 6. You can use
column G to get your totals.
 
G

Guest

Hello,

I have a question. Same situation as Jeff's but what if one of column
F (say... 761) returns a #VALUES! because it's in the form of a formula and
still waiting for a value. How will you Sumif the values?

Thanks in advance,
ampm


Andy said:
Hi

Try this:
=SUMPRODUCT(--(B2:B100=6),--(C2:C100="F"),--(F2:F100))

Andy.
 
D

Dave Peterson

I'd use something like:
=SUM((B1:B999=6)*(C1:C999="f")*(IF(ISNUMBER(F1:F999),F1:F999)))

This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it
correctly, excel will wrap curly brackets {} around your formula. (don't type
them yourself.)

Adjust the range to match--but you still can't use the whole column.
Hello,

I have a question. Same situation as Jeff's but what if one of column
F (say... 761) returns a #VALUES! because it's in the form of a formula and
still waiting for a value. How will you Sumif the values?

Thanks in advance,
ampm
 
A

alan

Far as I know, sumif can only check 1 column in its first range...so
what I do is create a new column, where you concatenate your column B &
C...then use that concatenated column as the first range of the sumif

new column G
=B&C

copied down for each row results in:

G
6M
6M
6F
6F
6F

Then use this formula (assuming data starts in row 2)

sumif(G2:G6,"6F",F2:F6)

Based on your data, you get a result of 21,187


Hope this helps

Alan
 

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

Similar Threads


Top