+ Reply to Thread
Results 1 to 5 of 5

Count Unique Dates If formula

  1. #1
    Registered User
    Join Date
    07-18-2011
    Location
    Austin, TX
    MS-Off Ver
    Excel 2007
    Posts
    13

    Count Unique Dates If formula

    I need to count unique dates in a list (column B) based on what period they are in(column A) . I have been able to do this with a pivot table, but really need a formula so that I can filter out rows if needed. A spreadsheet is attached to show an example of the data. I would greatly appreciate any help with this.

    Thank you,
    April
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    06-26-2010
    Location
    Austin, TX
    MS-Off Ver
    Excel 2010
    Posts
    1,673

    Re: Need help with a 'Count Unique Dates If' formula

    Is it possible for a date to be in two periods? At a quick glance, I did not see that occurring. So, would a COUNTIF() work for you?

    Try this in cell C1 and drag down.
    =COUNTIF($B$2:$B$1018,B2)

    Pauley

  3. #3
    Forum Expert
    Join Date
    06-26-2010
    Location
    Austin, TX
    MS-Off Ver
    Excel 2010
    Posts
    1,673

    Re: Need help with a 'Count Unique Dates If' formula

    If dates can be shared across periods, you should be able to use Domski's code from a previous thread you started. I modified it a bit so that it always returns the same number for a given date and period.

    =SUMPRODUCT(--($A$2:$A$1018=A2),--($B$2:$B$1018=B2))

    Pauley

    {Hope we get some rain in Austin today}

  4. #4
    Forum Contributor
    Join Date
    02-22-2011
    Location
    Rhône Alpes, France
    MS-Off Ver
    Excel 2007
    Posts
    201

    Re: Need help with a 'Count Unique Dates If' formula

    Hi,
    Attached the "Count Unique Dates" with formula and pivot table.
    Hope this will help.
    Best regards
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    07-18-2011
    Location
    Austin, TX
    MS-Off Ver
    Excel 2007
    Posts
    13

    Re: Count Unique Dates If formula

    Thank you both for your suggestions!!

    Paulyb - Your second formula works well, but it is not quite what I am looking to do. So great that we got rain!

    jpr73- Your formulas based on the pivot table works, but is it possible to make it simpler?

    I have attached a spreadsheet with a pivot table that shows what I would like to do with a formula. The reason is that I want to be able to hide or filter out rows of data, so that they are not included in the count. I can't do that with the pivot table. Is it possible to translate this pivot into a formula? It just has to be as clean as possible and I am working with many tabs of data. I greatly appreciate your efforts in helping me with this!
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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