Forum Discussion
spandy34
3 years agoResponsive Resident
Calculating time Midnight
I have the table below. I have a Plannned Entry Time and a Planned Exist Time and a Planned Duration which are all Time fields. I have used the following formula for the Planned Duration Column P...
- 3 years ago
THis has solved it - thank you so much for your help
Planned Duration =IF([PlannedExitTime] = TIME(0,0,0),(TIME(23,59,59)- 'Procurement_Main_Data'[PlannedEntryTime])+TIME(0,0,1),[PlannedExitTime] - [PlannedEntryTime])
AndrewPF
3 years agoHelper V
Are you taking into account the fact that anything after midnight is the following day?
Do your time fields include a date?
See also:
Solved: Concatenate date and time from different columns i... - Microsoft Power BI Community
- spandy343 years agoResponsive Resident
no it doesn't include a date. I think that was the problem . I think I need some DAX thst says if the time equals midnight then it's handled differently than just [PlannedExitTime]-[PlannedEntryTime]