+ Reply to Thread
Results 1 to 11 of 11

Distinct list of dates from the large list based on criteria

  1. #1
    Registered User
    Join Date
    10-29-2016
    Location
    karachi
    MS-Off Ver
    2016
    Posts
    23

    Distinct list of dates from the large list based on criteria

    I have a large list of dates. I want to create a distinct list from the large list based on criteria, only values within a specific date interval as per the attached sample file. Appreciate any assistance in the matter. thanks
    Attached Files Attached Files

  2. #2
    Forum Contributor
    Join Date
    03-18-2014
    Location
    Singapore
    MS-Off Ver
    Excel 2016 / 2019
    Posts
    251

    Re: Distinct list of dates from the large list based on criteria

    Hi irfman

    Array =IFERROR(INDEX($A$2:$A$18, MATCH(0, COUNTIF(C$1:$C1,$A$2:$A$18) + (COUNTIF($A$2:$A$18, $A$2:$A$18)<>1), 0)), "")
    Non-Array =IFERROR(INDEX($A$2:$A$18, MATCH(0,INDEX(COUNTIF($D$1:D1, $A$2:$A$18)+(COUNTIF($A$2:$A$108, $A$2:$A$18)<>1),0,0), 0)), "")
    Attached Files Attached Files
    Christopher Yap

  3. #3
    Registered User
    Join Date
    10-29-2016
    Location
    karachi
    MS-Off Ver
    2016
    Posts
    23

    Re: Distinct list of dates from the large list based on criteria

    thanks bro, which formula is more effective (Array or non-array) considering that I have a huge amount of data.

  4. #4
    Registered User
    Join Date
    10-29-2016
    Location
    karachi
    MS-Off Ver
    2016
    Posts
    23

    Re: Distinct list of dates from the large list based on criteria

    Also, the formula doesn't use the start and end date., I want unique dates based on the selection criteria, is this possible? thanks

  5. #5
    Forum Contributor
    Join Date
    03-18-2014
    Location
    Singapore
    MS-Off Ver
    Excel 2016 / 2019
    Posts
    251

    Re: Distinct list of dates from the large list based on criteria

    Hi irfman,

    don't quite understand, you want to display a list of unique dates from Column A, how is this related to your start and end date ( I suppose can be derived from the unique date list)

    or you can explain further your desire result in table form

  6. #6
    Registered User
    Join Date
    10-29-2016
    Location
    karachi
    MS-Off Ver
    2016
    Posts
    23

    Re: Distinct list of dates from the large list based on criteria

    I don't want to display all unique values. Only values falling within the start and end date should be displayed. As per the existing formula, all unique values are displayed as follows:

    Unique distinct list
    4-Jan-09
    5-Jan-09
    8-Jan-09
    10-Jan-09
    12-Jan-09
    16-Jan-09
    17-Jan-09
    18-Jan-09
    28-Jan-09

    how can I get unique values falling between a range e.g. 10-Jan-09 to 15-Jan-09 (the answer should be 10-Jan-09, 12-Jan-09). Hope the query is clear now. Thanks

  7. #7
    Forum Contributor
    Join Date
    03-18-2014
    Location
    Singapore
    MS-Off Ver
    Excel 2016 / 2019
    Posts
    251

    Re: Distinct list of dates from the large list based on criteria

    Hi irfman

    Create a column to list out the unique dates in between the Start and End Date ( user input)
    Attached Files Attached Files

  8. #8
    Registered User
    Join Date
    10-29-2016
    Location
    karachi
    MS-Off Ver
    2016
    Posts
    23

    Re: Distinct list of dates from the large list based on criteria

    thanks a lot for the assistance

  9. #9
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,498

    Re: Distinct list of dates from the large list based on criteria

    Do not employ helper, just add criteria-statement before COUNTIF

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Quang PT

  10. #10
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,213

    Re: Distinct list of dates from the large list based on criteria

    Please try at
    C2 with 3 columns array
    =IFERROR(AGGREGATE(15,6,$A$2:$A$18/($A$2:$A$18>MAX(C$1:C1))/($A$2:$A$18>=$F$1)/($A$2:$A$18<=$F$2),1),"")



    or
    D2 a bit longer but faster with less array calculation 2 columns array
    =IFERROR(AGGREGATE(15,6,$A$2:$A$18/($A$2:$A$18>MAX(D$1:D1))/(ABS($A$2:$A$18-($F$2+$F$1)/2)<=($F$2-$F$1)/2),1),"")
    Attached Files Attached Files

  11. #11
    Registered User
    Join Date
    10-29-2016
    Location
    karachi
    MS-Off Ver
    2016
    Posts
    23

    Re: Distinct list of dates from the large list based on criteria

    Quote Originally Posted by Bo_Ry View Post
    Please try at
    C2 with 3 columns array
    =IFERROR(AGGREGATE(15,6,$A$2:$A$18/($A$2:$A$18>MAX(C$1:C1))/($A$2:$A$18>=$F$1)/($A$2:$A$18<=$F$2),1),"")



    or
    D2 a bit longer but faster with less array calculation 2 columns array
    =IFERROR(AGGREGATE(15,6,$A$2:$A$18/($A$2:$A$18>MAX(D$1:D1))/(ABS($A$2:$A$18-($F$2+$F$1)/2)<=($F$2-$F$1)/2),1),"")
    the formula resolved the issue in 2 ninutes which i couldn't do in the last two days. thanks for all the assistance.

+ 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. Count distinct values based on criteria (large data)
    By ifulao in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-02-2020, 05:31 AM
  2. Count Distinct Values With A Criteria In A Filtered List
    By JonnyBoy333 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-31-2019, 02:52 AM
  3. [SOLVED] Generate list of dates between dates based on criteria - Onsite/Offshore holidays
    By sreeks in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-21-2017, 12:37 AM
  4. [SOLVED] take list of dates, and merge into larger table based on criteria
    By Rerock in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 03-15-2016, 03:25 PM
  5. List of distinct numbers withing range and another list extracted
    By YasserKhalil in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 11-16-2014, 03:27 PM
  6. [SOLVED] Create a distinct list based on other criteria
    By tomtheappraiser in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-29-2014, 12:59 PM
  7. I have a large list of dates that i want to consolidate
    By stuartpool in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-05-2013, 05:23 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