Forum Discussion
Help with Durations/TimSpans
- Anonymous4 years ago
Hi Beefheart ,
Here's my solution.
1.Create a calculated column to calculate the minutes.
Minute = DATEDIFF([Start],[End],MINUTE)2.Create another calculated column to get the average time.
Average of JobLen = var _minute=AVERAGEX(FILTER('Jobs',[Task]=EARLIER(Jobs[Task])&&[Who]=EARLIER(Jobs[Who])),[Minute]) return INT(DIVIDE(_minute,60))&":"&INT(MOD(_minute,60))&":00"3.The column to get the medidan time.
Median Of JobLen = var _minute=MEDIANX(FILTER('Jobs',[Task]=EARLIER(Jobs[Task])&&[Who]=EARLIER(Jobs[Who])),[Minute]) return INT(DIVIDE(_minute,60))&":"&INT(MOD(_minute,60))&":00"You can check more details from the attachment.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Beefheart ,
Here's my solution.
1.Create a calculated column to calculate the minutes.
Minute = DATEDIFF([Start],[End],MINUTE)
2.Create another calculated column to get the average time.
Average of JobLen = var _minute=AVERAGEX(FILTER('Jobs',[Task]=EARLIER(Jobs[Task])&&[Who]=EARLIER(Jobs[Who])),[Minute])
return INT(DIVIDE(_minute,60))&":"&INT(MOD(_minute,60))&":00"
3.The column to get the medidan time.
Median Of JobLen = var _minute=MEDIANX(FILTER('Jobs',[Task]=EARLIER(Jobs[Task])&&[Who]=EARLIER(Jobs[Who])),[Minute])
return INT(DIVIDE(_minute,60))&":"&INT(MOD(_minute,60))&":00"
You can check more details from the attachment.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello Anonymous,
Just what I was after, thank you for taking the time to post such a detailed reply.
HelloOwenAuger,
Thank you also for taking the time to reply, I can see situations where your solution can be used also.
Rest assured, both solutions are now filed away on OneNote for future reference.
Thanks again both for your time,
Beefheart