Forum Discussion
DanielTraub
4 years agoRegular Visitor
Compare Dates with IF Function
Hi all, I have a table with some start and end dates in it. I want to compare those dates, to today. If today is within the start/end date time frame, then return a result of "in learning perio...
- 4 years ago
Learning Period = IF ( Installations[Date Learning Period Started] <= TODAY () && TODAY () <= Installations[Expected Learning Period End Date], "In Learning Period", IF ( TODAY () > Installations[Expected Learning Period End Date], "Pilot in progress", IF ( Installations[Date Learning Period Started] > TODAY (), "Upcoming/Pilot Prep" ) ) )
tamerj1
Community Champion
4 years agoHi DanielTraub
please use
Learning Period =
VAR TodayDate =
TODAY ()
RETURN
IF (
Installations[Date Learning Period Started] <= TodayDate
&& Installations[Expected Learning Period End Date] >= TodayDate,
"In Learning Period",
IF (
TodayDate > Installations[Expected Learning Period End Date],
"Pilot in progress",
IF (
Installations[Date Learning Period Started] > TodayDate,
"Upcoming/Pilot Prep"
)
)
)