Forum Discussion

Anth_NC_QN's avatar
Anth_NC_QN
Frequent Visitor
3 years ago
Solved

Duration format MIN:SEC in table

Hi everyone,   English is not my native language but i'll try to be as precise as possible. Sorry if i'm not clear. Please do ask me more details.   I've been trying to reproduce this excel table...
  • tamerj1's avatar
    3 years ago

    Hi Anth_NC_QN 
    Please try

    wait time =
    VAR WaitTime =
        CALCULATE (
            AVERAGE ( VM_DATA_QUANTI[waiting time] ),
            FILTER ( VM_DATA_QUANTI, VM_DATA_QUANTI[Année] = "2021" )
        )
    VAR TotalSeconds = WaitTime * 60
    VAR Seconds =
        MOD ( TotalSeconds, 60 )
    VAR Minutes =
        QUOTIENT ( TotalSeconds, 60 )
    RETURN
        TIME ( 0, Minutes, Seconds )

    You can then choose you preference of the time format type.