Forum Discussion

ElvirBotic's avatar
ElvirBotic
Helper III
4 years ago
Solved

Counting Blank Dates in Date Column

I am trying to solve a problem where I need to count a column "Date Completed" and find out how many records have a blank in the "Date Completed" column. I originally used Measure1 = CALCULATE ( COUNTBLANK ( Table1[DateCompleted] ), ALL ( Table1 ) ) and it gets me the result I am looking for, but I can't filter by month. When I use just Measure2 = COUNTBLANK ( Table1[DateCompleted] ) then my filtering does not prodcue a result. I just keep getting [blank] in the card visual with Measure2. I do not know what I am doing wrong. Probably something simple, but I just cannot seem to figure out what I did. There is a relationship to the DateDimension and it is a 1:* joined on DateCompleted. 

  • Hi ElvirBotic 

     

    Try this:

    Measure1 =
    COUNTROWS ( 'Table1' )
        - COUNTROWS ( FILTER ( 'Table1', Table1[DateCompleted] <> BLANK () ) )
    




    If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
    Appreciate your Kudos!!
    LinkedIn: 
    www.linkedin.com/in/vahid-dm/

     

     

     

     

1 Reply

  • Hi ElvirBotic 

     

    Try this:

    Measure1 =
    COUNTROWS ( 'Table1' )
        - COUNTROWS ( FILTER ( 'Table1', Table1[DateCompleted] <> BLANK () ) )
    




    If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
    Appreciate your Kudos!!
    LinkedIn: 
    www.linkedin.com/in/vahid-dm/