SumIf Question

T

Tasha

I have a list of names in cell a3:a25 and what to add the sum from column g.
please help
sumif (a3:a50,"Bob", g3:g50)
 
B

Bob Phillips

That looks right, that will add all values in G where the value in A is Bob.

Was there more to it?
 
M

Mike H

Hi,

There's nothing wrong with your formula so if it's not returning an answer
then suspect the data. First try this but note it will pick up Bob anywhere
in the cell

=SUMIF(A3:A50,"*Bob*",G3:G50)

If that doesn't work, try this. Put a 1 in an empty cell and copy it. Select
G3 - G50 and

Edit|Paste special - select 'Multiply' and click OK

Mike
 
R

Ron Coderre

If you want one formula to sum for 5 different names...
here are a couple approaches:
=SUM(SUMIF(A5:A50,{"alpha","bravo","charlie","delta","echo"},G5:G50))
or
=SUMPRODUCT((A5:A50={"alpha","bravo","charlie","delta","echo"})*G5:G50)

Also, you could reference a list, instead of putting the values in the
formula
Example:
I1:I5 contains this list:
Alpha
Bravo
Charlie
Delta
Echo

and the formula would now be a combination of the two above methods:
=SUMPRODUCT(SUMIF(A5:A50,I1:I5,G5:G50))

Does that help?

Regards,

Ron Coderre
Microsoft MVP (Excel)
 

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