+ Reply to Thread
Results 1 to 9 of 9

How To Use Index Match To Return A Sum of Range Given Criteria

  1. #1
    Forum Contributor
    Join Date
    01-07-2012
    Location
    Ontario
    MS-Off Ver
    365
    Posts
    157

    How To Use Index Match To Return A Sum of Range Given Criteria

    Hello,

    Can someone help me with this problem please. Cells B3 & B4 are input cells and what I would like to return is cell B5.

    In the attached example, I need to total the amounts in the column that match the one identified in B3 given the Row E is greater than B4.

    I hope that is clear enough.

    Thank you!
    Attached Files Attached Files
    Last edited by PaddyP; 05-20-2020 at 04:45 PM.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    This formula will do that:

    =SUMPRODUCT(($F$3:$O$3=B3)*($E$4:$E$10>=B4)*($F$4:$O$10))
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Forum Expert
    Join Date
    05-30-2012
    Location
    The Netherlands
    MS-Off Ver
    Office 365
    Posts
    14,987

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    C3 =Match(B3,$E$3:$O$3,0)+4

    C4 =Match(B4,$E$1:$E$10,1)+1

    C5 = 10 => 10 rows

    C8 =SUM(INDIRECT(ADRESS(C4,C3)&":"&ADRESS(C5,C3)))

    See the attached file.
    Notice my main language is not English.

    I appreciate it, if you reply on my solution.

    If you are satisfied with the solution, please mark the question solved.

    You can add reputation by clicking on the star * add reputation.

  4. #4
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,080

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    How about
    =SUMPRODUCT((F3:O3=B3)*(E4:E10>=B4)*(F4:O10))

  5. #5
    Forum Expert
    Join Date
    09-07-2014
    Location
    Israel
    MS-Off Ver
    office 365 for MAC
    Posts
    3,105

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    In B5:

    =SUM(OFFSET($F$3,MATCH(ROUNDUP($B$4,0),$E$4:$E$10,0),MATCH(B3,$F$3:$O$3,0)-1,COUNTIF($E$4:$E$10,">"&$B$4)))

  6. #6
    Forum Contributor
    Join Date
    01-07-2012
    Location
    Ontario
    MS-Off Ver
    365
    Posts
    157

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    Wow so many great solutions!Thanks to everyone for the quick reply!

    I see a few differences in the results but I got what I need.

    Thank you!

  7. #7
    Forum Contributor
    Join Date
    01-07-2012
    Location
    Ontario
    MS-Off Ver
    365
    Posts
    157

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    Special shout out goes your way as this is the one that works perfectly for my data set! Thank you!

    Forgot to quote below

  8. #8
    Forum Contributor
    Join Date
    01-07-2012
    Location
    Ontario
    MS-Off Ver
    365
    Posts
    157

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    Quote Originally Posted by oeldere View Post
    C3 =Match(B3,$E$3:$O$3,0)+4

    C4 =Match(B4,$E$1:$E$10,1)+1

    C5 = 10 => 10 rows

    C8 =SUM(INDIRECT(ADRESS(C4,C3)&":"&ADRESS(C5,C3)))

    See the attached file.
    Special shout out goes your way as this is the one that works perfectly for my data set! Thank you!

  9. #9
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,080

    Re: How To Use Index Match To Return A Sum of Range Given Criteria

    You're welcome & thanks for the feedback.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Index Match with Criteria - return list
    By UHD in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 01-30-2019, 12:23 PM
  2. Index/Match Help to return value based on 2 criteria
    By klkenny in forum Excel Formulas & Functions
    Replies: 18
    Last Post: 06-20-2018, 10:28 PM
  3. [SOLVED] Combining 3 Formulas: Return all Names that Match Criteria Using Index/Match
    By bchilme in forum Excel Formulas & Functions
    Replies: 20
    Last Post: 09-29-2014, 09:28 AM
  4. [SOLVED] INDEX MATCH trying to return a value between two criteria.
    By cyberkidkiller in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-19-2014, 09:48 AM
  5. [SOLVED] Using Index Match with a Criteria to return a minimum
    By david0985 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-18-2014, 12:59 PM
  6. Index Match using two criteria to return on of criteria values
    By RogueLeader in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 03-17-2014, 09:50 AM
  7. Replies: 1
    Last Post: 11-06-2013, 08:37 PM

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