+ Reply to Thread
Results 1 to 6 of 6

SUMIF with row and column conditions

  1. #1
    Registered User
    Join Date
    03-04-2015
    Location
    Charlotte, NC
    MS-Off Ver
    2010
    Posts
    3

    SUMIF with row and column conditions

    Good afternoon -

    I have been banging my head on the wall for 2 days now, and can't figure this one out.

    I have reporting in a not so Excel-friendly format that I'm trying to summarize without any manipulation. A pivot would work great, but the format does not lend itself to that.

    I have dates in Column A followed by a "Sub Total" field. I also have descriptors across the top in row 1 that I need to match, and either sum all the data (from B3:M27), or just the data in the "Sub Total" field (B29:M29). The "Sub Total" field is not static, and will change depending on the number of working days in the month, which is why I can't just reference row 29.

    I've tried SUMIF, SUMPRODUCT, INDEX, MATCH - and nothing is giving me what I need.

    In the attached file, and example would be to sum all values for column heading Z, which would be 11.

    Any ideas???
    Attached Files Attached Files

  2. #2
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: SUMIF with row and column conditions

    Try this

    =SUM(INDEX($B$3:$M$33,MATCH("Sub Totals:",$A$3:$A$33,0),0))

    As long as the data begins in row 3.
    I chose 33 basically because you said the length of the data is based on how many working days there are.
    Well, there can't possibly be more than 31 working days in the month, so it will never go beyond row 33.

  3. #3
    Registered User
    Join Date
    03-04-2015
    Location
    Charlotte, NC
    MS-Off Ver
    2010
    Posts
    3

    Re: SUMIF with row and column conditions

    Thanks for the response Jonmo1.

    So this gets me close. Your equation is summing everything in the Sub Totals row. Now I need to narrow in on just those values that are specific to columns with header "Z".

    The MATCH function seems to work well for data in columns. Doesn't appear to do so well for data in rows.

  4. #4
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: SUMIF with row and column conditions

    Try

    =SUMIF($B$1:$M$1,"Z",INDEX($B$3:$M$33,MATCH("Sub Totals:",$A$3:$A$33,0),0))

  5. #5
    Registered User
    Join Date
    03-04-2015
    Location
    Charlotte, NC
    MS-Off Ver
    2010
    Posts
    3

    Re: SUMIF with row and column conditions

    Eureka!

    You da man!

    Many thanks!

  6. #6
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: SUMIF with row and column conditions

    You're welcome.

+ 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. SUMIF with 2 conditions.
    By Martinac in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 12-15-2007, 05:03 AM
  2. SUMIF conditions
    By AAMIFC in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-14-2006, 11:30 PM
  3. sumif more conditions
    By Pierre via OfficeKB.com in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 01-02-2006, 06:55 PM
  4. SUMIF with 2 conditions
    By Simon in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-05-2005, 11:05 PM
  5. [SOLVED] sumif with two conditions
    By ww in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-30-2005, 10:25 PM

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