Chelsie Eiden's Duration
Hello
Can anyone help me with the DAX , I have created a column in table but total is not appearing at the end i am using table visual .
Total =
VAR StartTime = ('All Measures'[Mea_New_Gen_Reg_Tim])
VAR EndTime = ('UN_ASYMAN_TRACK'[Released_Date_Time])
VAR Difference = EndTime - StartTime
VAR TotalHours = INT(Difference * 24)
VAR TotalMinutes = INT(MOD(Difference * 24 * 60, 60))
VAR TotalSeconds = INT(MOD(Difference * 24 * 60 * 60, 60))
RETURN
IF(Difference < 0, BLANK(), FORMAT(TotalHours, "00") & ":" & FORMAT(TotalMinutes, "00") & ":" & FORMAT(TotalSeconds, "00"))
The total seems accurate. The date difference between the 2 dates seem to be 414 days and change hours. Did you want the total to appear as Days, Hours, Minutes and Seconds? If yes, please refer to below comment by nigeldavidmaxey on how to set this up to reflect days, hours, minutes and seconds.