Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Count new users based on usage logging

How can I create two column charts based on usage logging that shows the growth of users? I have the username and timestamp (among other metrics).   I want one chart to show the number of users tha...
  • v-lili6-msft's avatar
    6 years ago

    hi Anonymous 

    You could try this way as below:

    Step1:

    Add a YearMonth column for date column

    Step2:

    Use these two formula to create two measure for your requirement:

    new users = CALCULATE(DISTINCTCOUNT('Table'[username]),FILTER('Table','Table'[Date]=CALCULATE(MIN('Table'[Date]),ALLEXCEPT('Table','Table'[username]))))
    all unique users = CALCULATE(DISTINCTCOUNT('Table'[username]),FILTER(ALL('Table'),'Table'[Date]<=MAX('Table'[Date])))

    Result:

    and here is sample pbix file, please try it.

     

    Regards,

    Lin