Forum Discussion
How to modify my expression to force Vari % return as % ?
- 5 years ago
Select your measure in the Fields panel and then click on the % sign to format it as percent in the ribbon. Also, you should write that measure using a variable to keep it from calculating twice each time.
_Vari_%_REV =
VAR vResult =
DIVIDE (
[_YTD REV] - [_LYTD REV],
[_LYTD REV]
)
RETURN
IF (
ISBLANK ( vResult ),
1,
vResult
)Pat
Select your measure in the Fields panel and then click on the % sign to format it as percent in the ribbon. Also, you should write that measure using a variable to keep it from calculating twice each time.
_Vari_%_REV =
VAR vResult =
DIVIDE (
[_YTD REV] - [_LYTD REV],
[_LYTD REV]
)
RETURN
IF (
ISBLANK ( vResult ),
1,
vResult
)
mahoneypat Thank you very for sharing the right approach in writing expression. it is more structure.
Paul