+ Reply to Thread
Results 1 to 7 of 7

Sumifs and Table Filtering

  1. #1
    Registered User
    Join Date
    01-12-2018
    Location
    Cambridgeshire, UK
    MS-Off Ver
    2017
    Posts
    6

    Sumifs and Table Filtering

    Hi,

    This is one that's puzzled me for quite some time.
    I use a lot of tables (usually from SQL) and I generally report figures from tables using SUMIFS.

    Most of the time it works fine but, seemingly randomly, I run into problems with filtering.

    The problem is that I want my SUMIFS functions to always show summarised numbers from a table no matter what the filter state is. I'm finding that sometimes when I filter a table, all SUMIFS that fall outside of the filters criteria show zero - I would like them to continue to show the results as if the table wasn't filtered.

    I only seem to run into this problem now and again but when I do, it completely puzzles me - it seems that the default behaviour is for SUMIFS to show results no matter what the state of the filters are and, searching on the web I can see that most questions are going the other way - ie 'how do I get SUMIFS to recognise filters' - I'm completely confused.

    Example - I have a table coming in from SQL containing the TB for a large company. I have around 50 tabs that show P&L and Balance Sheet data for various divisions and departments of the business. If I filter the table, all of the sheets continue to show complete data (via SUMIFS).
    If I create a new spreadsheet and pull the same data in from SQL and create a sheet with several SUMIFS looking up data with different criteria and I then filter the table to show only one category - all SUMIFS that have criteria for other categories revert to zero.

    I'm not sure why i'm getting inconsistent results? ...is there a setting that I've missed?

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

    Re: Sumifs and Table Filtering

    Here's a thread from yesterday on the same issue: https://www.excelforum.com/excel-for...ble-cells.html

    Administrative Note:

    Members will tailor the solutions they offer to the version (NOT release number) of Office (Excel, NOT Windows) that you have. Please check that your forum profile is up-to-date in this respect. If you aren't sure, in Excel go to File | Account and report what it says below the MS logo at the top of that page. If your version is for Mac, please also state this. Thanks.
    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.

  3. #3
    Registered User
    Join Date
    01-12-2018
    Location
    Cambridgeshire, UK
    MS-Off Ver
    2017
    Posts
    6

    Re: Sumifs and Table Filtering

    Thanks Ali,

    I think it's slightly different - I want SUMIFS to work no matter what the table filters are doing (visible and non-visable cells) - which I think is the default behaviour.

    I'm getting inconsistent behaviour ...most of the time SUMIFS ignore the filter (which I like) but sometimes SUMIFS will only work on visible cells.

    I'm wondering if there's some kind of setting that I need to apply? ...or perhaps there's been a change in Excel. Most of my spreadsheets have evolved over years and therefore originated in previous versions of Excel - I seem to get the above problem a lot when I create a new spreadsheet (I'm using 365 MSO (16.0.13929.20206)).

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

    Re: Sumifs and Table Filtering

    Difficult to say ...

    Are you still using Excel 2017?

    There are instructions at the top of the page explaining how to attach your sample workbook.

    A good sample workbook has just 10-20 rows of representative data that has been desensitised. It also has expected results mocked up, relevant cells highlighted and a few explanatory notes.

  5. #5
    Registered User
    Join Date
    01-12-2018
    Location
    Cambridgeshire, UK
    MS-Off Ver
    2017
    Posts
    6

    Re: Sumifs and Table Filtering

    Quote Originally Posted by aligw View Post
    difficult to say ...

    Are you still using excel 2017?
    ms 365 mso (16.0.13929.20206)

  6. #6
    Registered User
    Join Date
    01-12-2018
    Location
    Cambridgeshire, UK
    MS-Off Ver
    2017
    Posts
    6

    Re: Sumifs and Table Filtering

    Ah - I've fixed my own problem!

    I'd added a custom column to the SQL table which summed the months of the financial year using autosum - I didn't check but autosum automatically created a SUBTOTAL function (=SUBTOTAL(9,DB_Con_TBQ_2022[[Oct-21]:[Mar-22]])) and therefore hidden rows would be zero!

    I've change the formula to =SUM(DB_Con_TBQ_2022[[Oct-21]:[Mar-22]]) and now everything works!!

    ...this has been bugging me for a couple of years - I guess coming on here has forced me to think about it in enough detail to solve the problem!

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

    Re: Sumifs and Table Filtering

    ms 365 mso (16.0.13929.20206)
    Please update your forum profile NOW. Thanks.

    And thanks for letting us know.

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

    Also, if you have not already done so, you may not be aware that you can thank those who have helped you by clicking the small star icon (* Add Reputation) located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of all those who offered help.

+ 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. Replies: 1
    Last Post: 09-19-2021, 08:29 PM
  2. [SOLVED] Need help in filtering with a SUMIFS formula.
    By Herrerag92 in forum Excel General
    Replies: 3
    Last Post: 01-31-2020, 09:48 AM
  3. Filtering SUMIFS values largest to smallest
    By sbeatty in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 07-07-2017, 02:56 AM
  4. [SOLVED] how can i sum pivot table filtering some values another table
    By moogii1102 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-19-2014, 02:17 AM
  5. Filtering a table based on current cell in another table
    By bobarnett in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-02-2013, 10:44 AM
  6. Filtering data from the results of a sumifs formula
    By marks_28 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-27-2013, 11:55 AM
  7. Filtering Table B by the results in a column of Table A
    By GreenTee in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 01-17-2013, 10:10 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