Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
pdgaustintexas
 
Posts: n/a
Default Adding amounts that fall within a range


I need a formula that will add amounts in Column B if it falls within
certain range in Column C.

If Column C is greater than 725, then add amount in Column B (answer
will be $47).
If Column C is greater than 600, but less than 725, then add amount in
Column B (answer will be $45), and so.
Ex:
A B C
Joe $10 655
Jim $20 745
Tom $25 550
Sam $27 738
Amy $35 627


--
pdgaustintexas
------------------------------------------------------------------------
pdgaustintexas's Profile: http://www.excelforum.com/member.php...o&userid=30600
View this thread: http://www.excelforum.com/showthread...hreadid=503537

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bernard Liengme
 
Posts: n/a
Default Adding amounts that fall within a range

Hi Texan:
If Column C is greater than 725, then add amount in Column B (answer
will be $47).

=SUMPRODUCT(--(C1:C100725), B1;B100)
=SUMPRODUCT(--(C1:C100D1), B1;B100) 'D1 has value 725
=SUMIF(C1:C100,"725",B1:B5)

If Column C is greater than 600, but less than 725, then add amount in
Column B (answer will be $45), and so

=SUMPRODUCT(--(C1:C100600),--(C1:C100<725),B1:B100)
=SUMIF(C1:C100,"600",B1:B100) - SUMIF(C1:C100,"=725",B1:B100)

You cannot reference an entire column such as A:A in Sumproduct
For details visit http://www.xldynamic.com/source/xld.SUMPRODUCT.html
--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"pdgaustintexas"
<pdgaustintexas.21yg0m_1137796806.7659@excelforu m-nospam.com wrote in
message news:pdgaustintexas.21yg0m_1137796806.7659@excelfo rum-nospam.com...

I need a formula that will add amounts in Column B if it falls within
certain range in Column C.

If Column C is greater than 725, then add amount in Column B (answer
will be $47).
If Column C is greater than 600, but less than 725, then add amount in
Column B (answer will be $45), and so.
Ex:
A B C
Joe $10 655
Jim $20 745
Tom $25 550
Sam $27 738
Amy $35 627


--
pdgaustintexas
------------------------------------------------------------------------
pdgaustintexas's Profile:
http://www.excelforum.com/member.php...o&userid=30600
View this thread: http://www.excelforum.com/showthread...hreadid=503537



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ken Johnson
 
Posts: n/a
Default Adding amounts that fall within a range

Hi pdgaustintexas,
If you have to test with a lot of upper and lower limits of the Column
C value you could type the upper limit in D1 and the lower limit in D2
and change Sandy's formulas to...

=SUMIF(C1:C5,""&$D$1,B1:B5)

=SUMIF(C1:C5,"<="&$D$1,B1:B5)-SUMIF(C1:C5,"<"&$D$2,B1:B5)

Ken Johnson



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ashish Mathur
 
Posts: n/a
Default Adding amounts that fall within a range

Hi,

You may want to try the following array formula (Ctrl+Shift+Enter).

=sum(if(c1:c5725,b1:b5))
=sum(if((c1:c5600)*(c1:c5<725),b1:b5))

Regards,


"pdgaustintexas" wrote:


I need a formula that will add amounts in Column B if it falls within
certain range in Column C.

If Column C is greater than 725, then add amount in Column B (answer
will be $47).
If Column C is greater than 600, but less than 725, then add amount in
Column B (answer will be $45), and so.
Ex:
A B C
Joe $10 655
Jim $20 745
Tom $25 550
Sam $27 738
Amy $35 627


--
pdgaustintexas
------------------------------------------------------------------------
pdgaustintexas's Profile: http://www.excelforum.com/member.php...o&userid=30600
View this thread: http://www.excelforum.com/showthread...hreadid=503537


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
Help with using range names in sum function soteman2005 Excel Worksheet Functions 2 November 28th 05 04:43 PM
Array to named range conversion... i-Zapp Excel Discussion (Misc queries) 4 October 25th 05 09:09 PM
Adding Cell Range with Text JohnHill Excel Worksheet Functions 2 August 1st 05 03:30 AM
Problem adding a range using Sumif function. vrk1 Excel Worksheet Functions 2 June 22nd 05 06:05 PM
Adding Range Names John Excel Worksheet Functions 1 January 18th 05 11:56 AM


All times are GMT +1. The time now is 11:49 PM.

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

About Us

"It's about Microsoft Excel"