Forum Discussion
Anonymous
6 years agoNot applicable
IF Condition result
Hello guys, I have a formula that is something like this: RoadmapStart =
IF(
IF(
Roadmap[Aux] = "ROM",
Roadmap[ROM Start].[Date],
Roadmap[In Progress Start].[...
- 6 years agoIn this case, you could try variables:
Column=
VAR _Date = IF(
Roadmap[Aux] = "ROM",
Roadmap[ROM Start].[Date],
Roadmap[In Progress Start].[Date]
)
RETURN
IF(
_Date < DATE(2020,01,01),
DATE(2020,01,01),
_Date
)
Note though that variables are calculated when they are defined, not when they are used, so in some measures this can change their context. (not needed for this one, but good to know for future).
AllisonKennedy
Community Champion
6 years agoIn this case, you could try variables:
Column=
VAR _Date = IF(
Roadmap[Aux] = "ROM",
Roadmap[ROM Start].[Date],
Roadmap[In Progress Start].[Date]
)
RETURN
IF(
_Date < DATE(2020,01,01),
DATE(2020,01,01),
_Date
)
Note though that variables are calculated when they are defined, not when they are used, so in some measures this can change their context. (not needed for this one, but good to know for future).
Column=
VAR _Date = IF(
Roadmap[Aux] = "ROM",
Roadmap[ROM Start].[Date],
Roadmap[In Progress Start].[Date]
)
RETURN
IF(
_Date < DATE(2020,01,01),
DATE(2020,01,01),
_Date
)
Note though that variables are calculated when they are defined, not when they are used, so in some measures this can change their context. (not needed for this one, but good to know for future).