Forum Discussion
Average lead time
- 5 years ago
Hi Anonymous ,
Using your oringinal data "Seconds" for calculation would be better.
Create 2 measures as below:
average = AVERAGEX(ALLSELECTED('Table'),'Table'[Seconds])format = var _hour=INT('Table'[average]/3600) var _min=INT(DIVIDE('Table'[average]-_hour*3600,60)) var _sec=INT('Table'[average]-_hour*3600-_min*60) Return _hour&":"&_min&":"&_secAnd you would see:
For my related .pbix file,pls see attached.
Best Regards,
KellyDid I answer your question? Mark my post as a solution!
Anonymous , You need to convert to seconds average up and convert back
these blog have give that in details
https://radacad.com/calculate-duration-in-days-hours-minutes-and-seconds-dynamically-in-power-bi-using-dax
https://social.technet.microsoft.com/wiki/contents/articles/33644.powerbi-aggregating-durationtime-in-dax.aspx
https://www.pbiusergroup.com/communities/community-home/digestviewer/viewthread?GroupId=547&MessageKey=814a2cb4-3cca-4cd1-a620-c467adeaaaf6&CommunityKey=b35c8468-2fd8-4e1a-8429-322c39fe7110&tab=digestviewer
- Anonymous5 years agoNot applicable
Neither of these solutions seem to work. The radacad one, for example, where I directly copied the code, doesn't work for me. I have a similar date slider but this changes nothing, since the values remain at 0 hours, 0 minutes and 0 seconds. I'm not sure what I'm doing wrong here.