Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Re: Start Date and Date visual

Hi,   I have a table with the contract name, start date and end date. My date field are mm/dd/yyyy. I need to show a visual with count how many new contract came(started date) in a month and how ma...
  • Ashish_Mathur's avatar
    6 years ago

    Hi,

    You may download my PBI file from here.

    Hope this helps.

  • v-frfei-msft's avatar
    6 years ago

    Hi Anonymous ,

     

    1. Ceate a date table and related it to the fact table.

    date = ADDCOLUMNS(CALENDARAUTO(),"Y Month",FORMAT([Date],"YYYY-MMM"))

     

    2. After that, to create two measures as below to get the excepted result.

    end = CALCULATE(COUNTROWS('Table'),USERELATIONSHIP('Table'[End Date],'date'[Date]))
    Start = CALCULATE(COUNTROWS('Table'))

     

     

     

  • Anonymous's avatar
    Anonymous
    6 years ago

    Thank you. Your solution was easy to create and understood clearly.