#1   Report Post  
Betsey
 
Posts: n/a
Default SUMIF FUNCTION?

I need to sum two cells based on an age table.

If A2 is between two values (ie 15 & 29 then add cell C2 & G2; 45 & 49
then add C7 & G2)

There are 12 age bands.

My brain has stopped working and I know there has to be an easy way to do
this, but I'm not seeing it right now.

Thanks
  #2   Report Post  
Duke Carey
 
Posts: n/a
Default

Your question doesn't provide many details, so...

Assuming you have the lower numbers for each band in A2:A13, the higher
numbers in B2:B13, and the values to be added to G2 in the C2:C13 range, then

=SUMPRODUCT(--(A2:A13<=age),--(B2:B13=age),C2:C13)+G2

replace age with the address of the cell containing the age you are testing

If you truly want to test for an age being BETWEEN the upper & lower limits,
delete the equal signs

"Betsey" wrote:

I need to sum two cells based on an age table.

If A2 is between two values (ie 15 & 29 then add cell C2 & G2; 45 & 49
then add C7 & G2)

There are 12 age bands.

My brain has stopped working and I know there has to be an easy way to do
this, but I'm not seeing it right now.

Thanks

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
SumIF function ACDenver Excel Discussion (Misc queries) 2 August 17th 05 09:47 PM
SUMIF function yak10 Excel Worksheet Functions 0 February 12th 05 05:12 PM
SUMIF - Range name to used for the "sum_range" portion of a SUMIF function Oscar Excel Worksheet Functions 2 January 11th 05 11:01 PM
help with "criterea" in the sumif function [email protected] Excel Worksheet Functions 3 December 17th 04 06:27 PM
how do you do a sumif function on more than one worksheet? BMWPRO Excel Worksheet Functions 1 December 6th 04 08:26 PM


All times are GMT +1. The time now is 10:39 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"