+ Reply to Thread
Results 1 to 13 of 13

Sumifs and sumproduct sumrange issues

  1. #1
    Registered User
    Join Date
    02-14-2010
    Location
    Scotland
    MS-Off Ver
    MS Office 2013
    Posts
    35

    Sumifs and sumproduct sumrange issues

    Hi fellow forum users,

    I'm looking for some assistance with the following dilema, I can't seem to get it implemented in to my workbook.

    The Issue

    I have a sheet laid out like the following:-

    Description Category Jan Feb Mar Apr May ....Continues for the year....
    From To 1 2 3 4 5 ......................................

    Sales 1 100 101 £950 £850 £945 £990 £1,100
    Sales 2 102 105 £220 £120 £320 £192 £350
    Sales 3 106 112 £320 £256 £147 £241 £233

    I need to be able to sum all the months from a specified number along with the ability to filter out only relevant items that fall within the category range..

    For example:-

    I will have another cell that will define the month number and a from/to category with the idea it will only sum the items that fit in that criteria, let's say in this case I'm looking to sum anything with a category between 100 - 105 and all values up to month 2 (February).

    In this case the answer returned should be £950+£850+£220+£120. I have tried using sumproduct and sumifs, however the formula breaks down when I try to apply a sum range over multiple columns.

    Any help would be much appreciated.

    Thanks again

    Stuart

  2. #2
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Sumifs and sumproduct sumrange issues

    Can you post a SMALL sample file and show us what result(s) you expect.

    A SMALL sample file will have about 20 rows worth of data.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  3. #3
    Registered User
    Join Date
    02-14-2010
    Location
    Scotland
    MS-Off Ver
    MS Office 2013
    Posts
    35

    Post Re: Sumifs and sumproduct sumrange issues

    Yes no problem, I have created a quick sample workbook.
    Attached Files Attached Files

  4. #4
    Valued Forum Contributor
    Join Date
    05-14-2012
    Location
    Unknown
    MS-Off Ver
    Unseen
    Posts
    429

    Re: Sumifs and sumproduct sumrange issues

    Try:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    12-23-2003
    Posts
    179

    Re: Sumifs and sumproduct sumrange issues

    @InvisibleMan

    What does the *-- bit mean?

  6. #6
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,152

    Re: Sumifs and sumproduct sumrange issues

    Try

    =SUMPRODUCT(--($B$4:$B$15>=$B$21)*--($C$4:$C$15<=$B$22)*($D$4:$O$15)*($D$3:$O$3<=$B$18))

  7. #7
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Sumifs and sumproduct sumrange issues

    I think one of these will do what you want...

    =SUMIFS(INDEX(D4:O15,,B18),B4:B15,">="&B21,C4:C15,"<="&B22)

    =SUMPRODUCT(--(B4:B15>=B21),--(C4:C15<=B22),INDEX(D4:O15,,B18))

  8. #8
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,152

    Re: Sumifs and sumproduct sumrange issues

    OP wants CUMULATIVE months ... See example he quotes ..

    all values up to month 2 (February).

  9. #9
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Sumifs and sumproduct sumrange issues

    Ooops! Missed that part.

    In that case, try this...

    =SUMPRODUCT((B4:B15>=B21)*(C4:C15<=B22)*INDEX(D4:O15,,1):INDEX(D4:O15,,B18))

  10. #10
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Sumifs and sumproduct sumrange issues

    Another way array-entered.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    If you aren’t familiar with array-entered formulas array enter means the formula must be committed from edit mode by simultaneously pressing and holding down Ctrl and Shift while hitting Enter.
    Dave

  11. #11
    Registered User
    Join Date
    02-14-2010
    Location
    Scotland
    MS-Off Ver
    MS Office 2013
    Posts
    35

    Re: Sumifs and sumproduct sumrange issues

    Hi Guys,

    Spot on, absolutely nailed it.

    Thanks again.

  12. #12
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Sumifs and sumproduct sumrange issues

    You're welcome. We appreciate the feedback!

  13. #13
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Sumifs and sumproduct sumrange issues

    Yes. 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. Issues with INDIRECT and SUMIFS
    By dchubbock in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-25-2015, 09:25 AM
  2. [SOLVED] SUMIFS Using VLOOKUP to Define SUMRANGE
    By HangMan in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 04-26-2015, 02:22 PM
  3. [SOLVED] Advice needed - SUMIFS/SUMPRODUCT Issues
    By mo4391 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 04-23-2015, 02:35 PM
  4. [SOLVED] SUMIFS Issues
    By wat in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 02-15-2015, 03:26 PM
  5. Does SUMIFS have issues with merged cells or across multiple sheets??
    By dumaser88 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 09-09-2014, 01:04 PM
  6. Sumifs & Dynamic Sumrange
    By amartin575 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-24-2013, 10:02 AM
  7. SUMIFS formula with date format issues
    By swanseaexcel in forum Excel General
    Replies: 4
    Last Post: 04-18-2011, 05:25 AM

Tags for this Thread

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