Conditional Sum?

  • Thread starter Thread starter benji21
  • Start date Start date
B

benji21

I'm working with cellphone info. In one column is the category of
minutes (Weekend, anytime, etc) and in an adjacent column is the number
of minutes for the call. Is there a way to pull the sum of all where the
value of teh category column is set to a specific value (eg sum of
anytime minutes used)? I'm coming more from a database world and the
SQL woudln't be too tough but this is different... I thought about
applyingn a sort based on the category and then manually defining a sum
range, but is there a way without resorting? Thanks...

-Ben
 
MrShorty said:
Without more information, I would first suggest the SUMIF function.

Thanks for the response. What parameter do I use in the sumif to refer
to a changing column? "If B{X} equals value Y". I can't hardcode a row
number in, as it will need to compare for each individual row. Any
thoughts?
 
standard format for the SUMIF functions is =SUMIF(condition range
condition, sum range). So something along the lines o
=SUMIF(A1:A10,"weekday",B1:B10) would sum all of the entries in B1:B1
which correspond to the word "weekday" in A1:A10. Excel help usuall
has these functions pretty well documented
 
Thanks... Worked like a charm.

-Ben
standard format for the SUMIF functions is =SUMIF(condition range,
condition, sum range). So something along the lines of
=SUMIF(A1:A10,"weekday",B1:B10) would sum all of the entries in B1:B10
which correspond to the word "weekday" in A1:A10. Excel help usually
has these functions pretty well documented.
 
Back
Top