+ Reply to Thread
Results 1 to 11 of 11

Combine two filter formulas

  1. #1
    Registered User
    Join Date
    03-02-2024
    Location
    UK
    MS-Off Ver
    365
    Posts
    54

    Combine two filter formulas

    Hello,

    I would like to combine two filter formulas (or something equivalent) as they are pulling results from two different sheets:

    =FILTER(DeadSummary!B3:E50000,(DeadSummary!B3:B50000>"0"))

    The one above with:

    =FILTER(Summary!D8:H50000,(Summary!D8:D50000>"0")) - In this one, would it also be possible to modify it to skip a Column? As in filter Column D, E, F, G, H and J (skipping Column I completely)

    Is something like this possible? Been trying for hours but got stuck at this point. Do let me know if it's required an example sheet, can try to do one tomorrow.

    Thank you in advance

  2. #2
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,465

    Re: Combine two filter formulas

    First question:
    Please try
    Formula: copy to clipboard
    Please Login or Register  to view this content.


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

  3. #3
    Registered User
    Join Date
    03-02-2024
    Location
    UK
    MS-Off Ver
    365
    Posts
    54

    Re: Combine two filter formulas

    Hello HansDouwe and thank you for your reply,

    Sorry for lack of example sheet, I'm doing one at the moment (it was late and my brain had given up). Will attached it as soon as I finish

    But your first formula gives me a "too few arguments" error and the second formula "too many"

    Help.xlsx
    Last edited by ExcelNewbie92; 04-28-2024 at 03:50 AM.

  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. 2406 (Windows 11 23H2 64-bit)
    Posts
    82,699

    Re: Combine two filter formulas

    Try:

    =IFNA(VSTACK(FILTER(DeadSummary!B3:E50000,DeadSummary!B3:B50000>0),FILTER(Summary!D8:H50000,Summary!D8:D50000>0)),"")

    and:

    =IFNA(VSTACK(FILTER(DeadSummary!B3:E50000,DeadSummary!B3:B50000>0),CHOOSECOLS(FILTER(Summary!D8:J50000,Summary!D8:D50000>0),1,2,3,4,5,7)),"")

    0 does NOT need to be in inverted commas - it's not text.
    Last edited by AliGW; 04-28-2024 at 03:43 AM.
    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.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  5. #5
    Registered User
    Join Date
    03-02-2024
    Location
    UK
    MS-Off Ver
    365
    Posts
    54

    Re: Combine two filter formulas

    Hello AliGW, Your second one doesn't give an error but the last 2 Columns are not showing up. Also if possible could it just be one formula pulling the values and adding everything?

    I've finished the example sheet with some notes on it. Thanks for the zero information!

    Help.xlsx

  6. #6
    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. 2406 (Windows 11 23H2 64-bit)
    Posts
    82,699

    Re: Combine two filter formulas

    Cheeky - you seem to have added extra criteria in the workbook. Please don't do this - you seem to have a habit of drip-feeding your requirements, and this just adds to your helpers' workload. Please declare EVERYTHING in your opening post.

    New requirements:

    From the DeadSummary starting at B3 to E3 all the way until B="0"

    From Summary starting at D8 to J8 BUT ignoring Column I please.

    Even better if all could be sorted automatically by Column A smaller to largest values
    Anything else you haven't told us???
    Last edited by AliGW; 04-28-2024 at 03:59 AM.

  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. 2406 (Windows 11 23H2 64-bit)
    Posts
    82,699

    Re: Combine two filter formulas

    Maybe try this:

    =SORT(IFNA(VSTACK(FILTER(DeadSummary!B3:E50000,DeadSummary!B3:B50000>0),CHOOSECOLS(FILTER(Summary!D8:J50000,Summary!D8:D50000>0),1,2,3,4,5,7)),""))

  8. #8
    Registered User
    Join Date
    03-02-2024
    Location
    UK
    MS-Off Ver
    365
    Posts
    54

    Re: Combine two filter formulas

    Thanks again AliGW, and I do apologise, sometimes as I'm doing think of things that could also be done/improved, will try to avoid that in the future

    That last formula almost does the trick! However the sorting is the only thing not right, due to the number not being in order and having letters I can only take into consideration the last 4 digits. That's why on sheet3 I have =RIGHT(B2,4) to then sort them accordingly. Just try to do the same manually which I would be happy to but it says that I can't change part of an array

    What if I did the =RIGHT(B2,4) on the Summary and DeadSummary, would it be any easier for your formula to sort the numerical from smaller to largest?

  9. #9
    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. 2406 (Windows 11 23H2 64-bit)
    Posts
    82,699

    Re: Combine two filter formulas

    Any better?

    =LET(a,IFNA(VSTACK(FILTER(DeadSummary!B3:E50000,DeadSummary!B3:B50000>0),CHOOSECOLS(FILTER(Summary!D8:J50000,Summary!D8:D50000>0),1,2,3,4,5,7)),""),SORTBY(a,RIGHT(INDEX(a,,1),4)))
    Attached Files Attached Files
    Last edited by AliGW; 04-28-2024 at 04:16 AM. Reason: Workbook added.

  10. #10
    Registered User
    Join Date
    03-02-2024
    Location
    UK
    MS-Off Ver
    365
    Posts
    54

    Re: Combine two filter formulas

    AliGW, I'm speechless you are amazing!!! That did the trick. Thread solved

  11. #11
    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. 2406 (Windows 11 23H2 64-bit)
    Posts
    82,699

    Re: Combine two filter formulas

    You are welcome.

    You know how to sign off the thread.

+ 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: 2
    Last Post: 10-24-2021, 08:03 AM
  2. Looking to combine and filter tables
    By mpuchtel in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-09-2019, 09:07 PM
  3. How to Combine 2 Formulas into 1?
    By honeybee99 in forum Excel General
    Replies: 1
    Last Post: 11-22-2018, 11:31 PM
  4. [SOLVED] Can you combine these two formulas?
    By TheN in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 08-17-2016, 07:57 PM
  5. [SOLVED] How to combine four formulas into one?
    By JohnJK04 in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 07-31-2015, 07:13 PM
  6. [SOLVED] Using Combine macro to combine multiple worksheets - need to modify to paste formulas
    By DLSmith in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-26-2012, 09:07 AM
  7. [SOLVED] Combine 2 formulas
    By Steved in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-08-2005, 06:05 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