Forum Discussion

browna6's avatar
browna6
Frequent Visitor
2 years ago
Solved

Sum up the difference between two times as a numeric value

Hi   I have sample data where i am trying to summarise by Area and show the minimum time and the maximum time in each area. Then show the difference between to two times to give me the Total Hours/...
  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi  browna6 ,

     

    You can try the following measure:

    Measure =
    var _table=SUMMARIZE('Table','Table'[Area],"Value",[Hours])
    return
    IF(
        HASONEVALUE('Table'[Area]),[Hours],SUMX(_table,[Value]))

     

     

    Best Regards,

    Liu Yang

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.