+ Reply to Thread
Results 1 to 12 of 12

Filter without result to show blank for Vstack

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    10-02-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    285

    Filter without result to show blank for Vstack

    Hi, i am filtering both Start and End with a day.

    However, my formula only work without error IF both filter return a valid result.
    How do i solve this?

    Please see my file
    Attached Files Attached Files

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

    Re: Filter without result to show blank for Vstack

    Please try:
    =LET(
      start,FILTER(Table1,EOMONTH(--CHOOSECOLS(Table1,2),0)=$E$1),
      end,(FILTER(Table1,EOMONTH(--CHOOSECOLS(Table1,3),0)=$E$1)),
      t,VSTACK(start,end),
      IF(t="","",t))
    Attached Files Attached Files

  3. #3
    Forum Contributor
    Join Date
    10-02-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    285

    Re: Filter without result to show blank for Vstack

    Hi, thanks for your help. But my actual file has some calculation in using the date. It still shows error.

    Give me a minute. I update my excel. Sorry.
    Last edited by AliGW; 01-08-2024 at 03:35 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  4. #4
    Forum Contributor
    Join Date
    10-02-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    285

    Re: Filter without result to show blank for Vstack

    Hi, HansDouwe, just discover that you misunderstood my meaning. My file, if i change G1 to other day like 30/07/2023, i will get a #CALC! error, i believe its due to becoz one of the filter return nil.

    Hence i am trying to make it show only valid result.
    Attached Files Attached Files
    Last edited by AliGW; 01-08-2024 at 03:39 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  5. #5
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,662

    Re: Filter without result to show blank for Vstack

    Try:
    =LET(
    start,FILTER(Table1,EOMONTH(--CHOOSECOLS(Table1,2),0)=$G$1),
    end,(FILTER(Table1,EOMONTH(--CHOOSECOLS(Table1,3),0)=$G$1)),
    IFERROR(VSTACK(start,end),""))
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  6. #6
    Forum Contributor
    Join Date
    10-02-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    285

    Re: Filter without result to show blank for Vstack

    Hi, the formula do not work if i type 31/05/2023 and 31/10/2023. If i type in 31/05/2023, it should show only the Start and End should be nil.

    However, i get no result. Kindly help.
    Last edited by AliGW; 01-08-2024 at 12:58 PM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  7. #7
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,662

    Re: Filter without result to show blank for Vstack

    Post a file showing what you ecxpect to see for 31/5/23. I must have misunderstood you, as there are NO values that START in may 23 and which also END in May 23... which was my understanding of your requirement.

  8. #8
    Forum Contributor
    Join Date
    10-02-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    285

    Re: Filter without result to show blank for Vstack

    Hi, please see attached. Thanks for your help.

    Really appreciate.
    Attached Files Attached Files

  9. #9
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,662

    Re: Filter without result to show blank for Vstack

    I asked for expected answers, not a non-working formula. So another (final) guess.

    If this is still incorrect, I need a proper explanation and expected results.
    Attached Files Attached Files

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

    Re: Filter without result to show blank for Vstack

    Please try this formula:
    Formula: copy to clipboard
    =LET(f,FILTER(Table1,Table1[Start]<=G1,Table1[End]>=G1),IF(f="","",f))
    Attached Files Attached Files

  11. #11
    Forum Expert
    Join Date
    01-05-2013
    Location
    Singapore
    MS-Off Ver
    H&B2019
    Posts
    4,542

    Re: Filter without result to show blank for Vstack

    Modifying Hans' formula in post #2,
    PHP Code: 
    =IFERROR(LET(
      
    start,FILTER(Table1,EOMONTH(--CHOOSECOLS(Table1,2),0)=EOMONTH($G$1,0)),
      
    end,IFERROR(FILTER(Table1,EOMONTH(--CHOOSECOLS(Table1,3),0)=EOMONTH($G$1,0)),""),
      
    t,VSTACK(start,end),
      IF(
    t="","",t)),""

  12. #12
    Forum Contributor
    Join Date
    10-02-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 365
    Posts
    285

    Re: Filter without result to show blank for Vstack

    Hi to all, thanks everyone there for your 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. Sorting Results from VSTACK, FILTER with CHOOSECOLS
    By drvs in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 11-28-2023, 03:51 PM
  2. [SOLVED] Add Additional FILTER to VSTACK
    By BiblioManiac in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-22-2023, 03:32 PM
  3. [SOLVED] Problem when filter named ranges using VSTACK
    By oteixeira in forum Excel General
    Replies: 6
    Last Post: 01-18-2023, 03:37 PM
  4. Filter result show in the Listbox
    By curiousyoung60 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-21-2022, 10:33 AM
  5. [SOLVED] formula check if blank if not show result
    By scouse13 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 09-27-2020, 12:17 PM
  6. [SOLVED] Where formula does not result in #N/A to show blank
    By Howardc1001 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-14-2020, 07:15 AM
  7. Replies: 1
    Last Post: 02-10-2018, 11:35 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