Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi i have the below dax calculation
I have a start time and end time and difference between the two, all columns are formatted as Time
Solved! Go to Solution.
@maurcoll Try:
VAR TotalSeconds=SUMX('Duration',HOUR('Duration'[Time])*3600 +MINUTE('Duration'[Time])*60+SECOND('Duration'[Time]))
VAR Days =TRUNC(TotalSeconds/3600/24)
VAR Hors = TRUNC((TotalSeconds-Days*3600*24)/3600) + (Days * 24)
VAR Mins =TRUNC(MOD(TotalSeconds,3600)/60)
VAR Secs = MOD(TotalSeconds,60)
return
IF(Hors<10,"0"&Hors,Hors)&":"&IF(Mins<10,"0"&Mins,Mins)&":"&IF(Secs<10,"0"&Secs,Secs)
@maurcoll Try:
VAR TotalSeconds=SUMX('Duration',HOUR('Duration'[Time])*3600 +MINUTE('Duration'[Time])*60+SECOND('Duration'[Time]))
VAR Days =TRUNC(TotalSeconds/3600/24)
VAR Hors = TRUNC((TotalSeconds-Days*3600*24)/3600) + (Days * 24)
VAR Mins =TRUNC(MOD(TotalSeconds,3600)/60)
VAR Secs = MOD(TotalSeconds,60)
return
IF(Hors<10,"0"&Hors,Hors)&":"&IF(Mins<10,"0"&Mins,Mins)&":"&IF(Secs<10,"0"&Secs,Secs)
User | Count |
---|---|
85 | |
78 | |
70 | |
49 | |
41 |
User | Count |
---|---|
111 | |
56 | |
50 | |
42 | |
40 |