Forum Discussion

vsinne's avatar
vsinne
Frequent Visitor
8 years ago
Solved

Power BI Total Time Calculation

Hello All,

 

I am trying to calculate overall time an agent had spent on different task in Power BI Desktop. Please help me resolve this issue. We have multiple agent who are working on different task at the same time. each task requires different time period to perform. i want to know overall time spent by each agent on different tickets. Thank you all for your help. 

 Agent IDJob Performed Time 
 13D Print0:20:00 
 2Fabrication0:30:00 
 2CAD16:00:00 
 2Design Help1:00:00 
 3ME5:00:00 
 3ME6:00:00 
 4CAD1:00:00 
 43D print0:30:00 
 43D Print0:30:00 
  • Hi vsinne,

     

    Please check out the attachment. If it's what you want?

    TimeCosts =
    VAR total =
        SUM ( Table1[Seconds] )
    VAR hours =
        INT ( total / 3600 )
    VAR minutes =
        INT ( MOD ( total, 3600 ) / 60 )
    VAR seconds =
        MOD ( MOD ( total, 3600 ), 60 )
    RETURN
        hours & " hours "
            & minutes
            & " minutes "
            & seconds
            & " seconds"
    

    Power_BI_Total_Time_Calculation

     

    Best Regards,

    Dale

5 Replies