Forum Discussion
Anonymous
6 years agoNot applicable
TimeDifference with two times
Hi, Could please help with the calculation here? My measure calculation is trying to subtract the times 'sdate' and 'edate' and below should be 2:10 and its displaying as 3:00 on the card. ...
- 6 years ago
Anonymous , the first way to take diff is that you create it as column
New column = [Time1] -[time2]
measure optionsmeasure 1 = sumx(Table, Table[Time1] -Table[time2]) //you can use averageX
calculate( min(Table[Time1] ) -max(Table[time2]) , values(Table[ID])) // force row context, but Gt will wrongrefer for row context
amitchandak
6 years agoSuper User
Anonymous , what are you try to achieve here ?
Anonymous
6 years agoNot applicable
Hi amitchandak ,
I have a couple of If statements
IF(SUMX(RoomUtilisation, RoomUtilisation[New End Date]>[ParameterEndDate]),1,
IF(SUMX(RoomUtilisation, RoomUtilisation[New End Date]<[ParameterEndDate]),2,
IF(SUMX(RoomUtilisation, RoomUtilisation[New End Date]<= [ParameterEndDate]),3,0
It says SUMX cannot work with type Boolean. Ive checked the formatting and all is correct.