Forum Discussion
Anonymous
3 years agoNot applicable
Time diff format calculation measure
Hey I m trying to convert calculation into time format but with no luck ( i have been trying to use mod/ int functions and adding "min" "sec" text). The aim is to apply is to a chart Original fo...
v-xiaotang
3 years agoCommunity Support
Hi Anonymous
Thanks for reaching out to us.
you have to convert calculation into time format by using measure like below,
example:
fmtCol =
RIGHT ( "0" & INT ( TableName[Duration] / 3600 ), 2 )
& ":"
& RIGHT (
"0"
& INT ( ( TableName[Duration] - INT (TableName[Duration] / 3600 ) * 3600 ) / 60 ),
2
)
& ":"
& RIGHT ( "0" & MOD (TableName[Duration], 3600 ), 2 )
Solved: formatting time value to hh:mm:ss - Microsoft Power BI Community
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.