Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
9 years ago
Solved

How to minus the Date/Time format ?

Hi All,   I created in table Dim Date an calculated column called GetTime. This GetTime ( formula Gettime = NOW() )  gives a current time from my PowerBI Desktop.   The current time is now at 13:...
  • v-jiascu-msft's avatar
    9 years ago

    Hi Anonymous,

     

    You can try this formula in your scenario.

    ResultMeasure =
    MIN ( 'Table1'[GetTimeCol] )
        + SIGN ( MIN ( 'Table1'[Time] ) ) * TIME ( 0, ABS ( MIN ( 'Table1'[Time] ) ), 0 )

    I would suggest that we create a calculated column instead, which would be simpler.

     

    ResultCol =
    [GetTimeCol]
        + SIGN ( [Time] ) * TIME ( 0, ABS ( [Time] ), 0 )

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

    Best Regards!

    Dale