+ Reply to Thread
Results 1 to 7 of 7

Adding amounts that fall within a range

  1. #1
    Registered User
    Join Date
    01-18-2006
    Posts
    7

    Question 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

  2. #2
    Sandy Mann
    Guest

    Re: Adding amounts that fall within a range

    For greater than 725 use:

    =SUMIF(C1:C5,">725",B1:B5)

    for greater than 600 and less then or equal to 725 try:

    =SUMIF(C1:C5,"<=725",B1:B5)-SUMIF(C1:C5,"<600",B1:B5)


    --
    HTH

    Sandy
    [email protected]
    [email protected] with @tiscali.co.uk


    "pdgaustintexas"
    <[email protected]> wrote in
    message news:[email protected]...
    >
    > 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
    >




  3. #3
    Don Guillett
    Guest

    Re: Adding amounts that fall within a range

    try
    =SUMIF(J:J,">"&725,K:K)
    =SUMPRODUCT((J2:J22>725)*I2:I22)


    =SUMPRODUCT((J2:J22>600)*(J2:J22<725)*I2:I22)
    --
    Don Guillett
    SalesAid Software
    [email protected]
    "pdgaustintexas"
    <[email protected]> wrote in
    message news:[email protected]...
    >
    > 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. #4
    Bernard Liengme
    Guest

    Re: 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:C100>725), B1;B100)
    =SUMPRODUCT(--(C1:C100>D1), 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:C100>600),--(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"
    <[email protected]> wrote in
    message news:[email protected]...
    >
    > 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. #5
    Ken Johnson
    Guest

    Re: 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. #6
    Ashish Mathur
    Guest

    RE: Adding amounts that fall within a range

    Hi,

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

    =sum(if(c1:c5>725,b1:b5))
    =sum(if((c1:c5>600)*(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
    >
    >


  7. #7
    Don Guillett
    Guest

    Re: Adding amounts that fall within a range

    Best not to use resource grabbing array formulae unless absolutely
    necessary. Sumif or sumproduct will work in this case.

    --
    Don Guillett
    SalesAid Software
    [email protected]
    "Ashish Mathur" <[email protected]> wrote in message
    news:[email protected]...
    > Hi,
    >
    > You may want to try the following array formula (Ctrl+Shift+Enter).
    >
    > =sum(if(c1:c5>725,b1:b5))
    > =sum(if((c1:c5>600)*(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 to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1