Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Running total with daily benchmarking

i would to have running total of survey and daily benchmarking of it. in attached excel file yellow highlighted is an main data of source, next two columns need to create as column or measure in same...
  • v-angzheng-msft's avatar
    5 years ago

    Hi, Anonymous 

    The desired result can be obtained by creating 3 measures.

    Create a measure to get the running total:

    Running Total =
    CALCULATE (
        SUM ( 'Table'[Survey Count] ),
        FILTER ( ALL ( 'Table' ), 'Table'[Date] <= MAX ( 'Table'[Date] ) )
    )
    

    To create a measure to identify the daily benchmark, you can manually change the parameters of this measure if you want.

    Daily Benchmark =
    VAR Total_Employees = 5000
    VAR Target_Rate = 0.9
    VAR Amount_of_days = 365
    RETURN
        Total_Employees * Target_Rate / Amount_of_days
    

    According to the data you provided, in this case, the current value is 12.3, and I created a card view to display this value

    Then we can create another new measure which based on Daily Benchmark to get Benchmark:

    Benchmark =
    CALCULATE (
        COUNTROWS ( FILTER ( ALL ( 'Table' ), 'Table'[Date] <= MAX ( 'Table'[Date] ) ) ) * 'Table'[Daily Benchmark]
    )
    

    Using these measures you can get the view you want.

    Result:

     

     

    Is this the result you want? Hope this is useful to you

    Please feel free to let me know If you have further questions

     

     

    Best Regards,
    Community Support Team _ Zeon Zheng
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.