+ Reply to Thread
Results 1 to 6 of 6

SUMIFS With merged cells

  1. #1
    Forum Contributor
    Join Date
    05-15-2015
    Location
    Orlando, FL
    MS-Off Ver
    Office Standard 2016
    Posts
    268

    SUMIFS With merged cells

    Hi everyone,

    Having trouble with a formula. In my spreadsheet, data spits out from a query where a project name (Column A) is merged between 3 rows. For example, row 4/5/6 are the project name. Column B has 3 rows in this order, "Base", "Override","Working". My issue is when doing a sumifs, its totaling 0, which I'm guessing is because of column A. Looking at the formula below, any idea how i might get this to work?

    Please Login or Register  to view this content.
    Row N is the value I want summed when column A contains the letters "SFL" and column B is equal to "Working".

    Any suggestions would be greatly appreciated.

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2502
    Posts
    26,892

    Re: SUMIFS With merged cells

    This is one reason nearly every expert here recommends against using merged cells. They can look pretty but they usually make for poor data layout design.

    My first recommendation is to get rid of merged cells and put the project name in every row.

    However, since in this case you are always looking in the third row of each group an alternative might be this, but I haven't tested it. Note that I have shifted down the range for the sum and range to search for Working. All three ranges must be the same shape, but they don't have to be the same rows:

    =SUMIFS('CF2 MP'!$N$6:$N$27002,'CF2 MP'!$B$6:$B$27002,"Working",'CF2 MP'!$A$4:$A$27000,"*SFL*")

    If this does not work please attach a file with test data, with no private data.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Valued Forum Contributor
    Join Date
    01-07-2013
    Location
    Michigan
    MS-Off Ver
    O365
    Posts
    601

    Re: SUMIFS With merged cells

    This might work, based on a very limited test range:
    Please Login or Register  to view this content.
    It has to be entered as an array formula (ctrl+shift+enter). It also assumes that "Working" is always the third value in B, and that there are never more than 3 rows per project.

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: SUMIFS With merged cells

    I echo 6String's comments regarding using merged cells - avoid at all costs.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,697

    Re: SUMIFS With merged cells

    Ditto both - with knobs on!
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  6. #6
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 insider Version 2505 Win 11
    Posts
    24,719
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

+ 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. Sumifs with criteria in merged cell
    By akpundir in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-05-2016, 06:42 AM
  2. [SOLVED] SUMIFS with one criteria range that contains merged cells
    By r4square in forum Excel General
    Replies: 5
    Last Post: 03-18-2015, 04:33 AM
  3. Replies: 0
    Last Post: 11-25-2014, 07:08 AM
  4. automatically fit an image into merged cells for full width of merged cells
    By Marcin4111 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 11-18-2014, 03:12 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. How to do a sumifs with criteria merged cells
    By vm82 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-05-2014, 09:16 AM
  7. Replies: 1
    Last Post: 06-28-2012, 11:53 AM

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