+ Reply to Thread
Results 1 to 6 of 6

Count Unique Instances of Date while filtering based upon date and ID #

  1. #1
    Registered User
    Join Date
    08-14-2014
    Location
    California, USA
    MS-Off Ver
    2010
    Posts
    3

    Count Unique Instances of Date while filtering based upon date and ID #

    Hello,

    I've been browsing several forums to try and find the answer to this, so far none of the suggested formulas have worked when I've copied them.

    I have a list of ID# (Col A) and dates (Col B). The ID # of reference is Col (F) and today's date (Col G). I need to count how many future dates there are in the list (Col B) that are unique and in the future from today's date.

    Any tips would be greatly appreciated, I'm still fairly new to all these formulas and functions which is why I'm not attempting this in VBA.

    I've attached an example work book and I would like the result in H2.
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor
    Join Date
    05-13-2010
    Location
    Belo Horizonte, Brazil
    MS-Off Ver
    Excel 2003; 2007
    Posts
    441

    Re: Count Unique Instances of Date while filtering based upon date and ID #

    pmambrosetti, Good evening.

    Try to use:

    H2 -->

    =SUMPRODUCT((A2:A12=F2)*(B2:B12>G2))

    Is it what you want?
    I hope it helps.
    ...If my answer helped you, Please, click on. * Add Reputation (at left)

    Best regards.
    Marc?lio Lob?o

  3. #3
    Registered User
    Join Date
    08-14-2014
    Location
    California, USA
    MS-Off Ver
    2010
    Posts
    3

    Re: Count Unique Instances of Date while filtering based upon date and ID #

    Thanks for replying!

    That counted all the future dates tied to that ID# and returned 7. How would I go about only returning the unique dates?

    The goal of this example would be to return 4 as the ID# 1234567 appears 7 times but only on 4 distinct dates.

    Does that make sense?

  4. #4
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Count Unique Instances of Date while filtering based upon date and ID #

    Try this array formula**:

    =SUM(IF(FREQUENCY(IF(A2:A12=F2,IF(B2:B12>G2,B2:B12)),B2:B12),1))

    ** array formulas need to be entered using the key
    combination of CTRL,SHIFT,ENTER (not just ENTER).
    Hold down both the CTRL key and the SHIFT key
    then hit ENTER.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  5. #5
    Registered User
    Join Date
    08-14-2014
    Location
    California, USA
    MS-Off Ver
    2010
    Posts
    3

    Re: Count Unique Instances of Date while filtering based upon date and ID #

    Quote Originally Posted by Tony Valko View Post
    Try this array formula**:

    =SUM(IF(FREQUENCY(IF(A2:A12=F2,IF(B2:B12>G2,B2:B12)),B2:B12),1))

    ** array formulas need to be entered using the key
    combination of CTRL,SHIFT,ENTER (not just ENTER).
    Hold down both the CTRL key and the SHIFT key
    then hit ENTER.
    That is exactly what I needed! Thank you so much, just made my Friday!

  6. #6
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Count Unique Instances of Date while filtering based upon date and ID #

    You're welcome. Thanks for the feedback!

+ 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: 8
    Last Post: 09-14-2013, 12:53 PM
  2. Replies: 1
    Last Post: 02-05-2013, 09:14 AM
  3. Count Unique based on date
    By dab1988 in forum Excel General
    Replies: 14
    Last Post: 08-25-2011, 08:17 AM
  4. Sort,Count & Sum data based on unique date
    By excelkeechak in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 07-26-2009, 06:57 AM
  5. count unique cells in range based on date
    By leedsd75 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-09-2007, 02:04 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