Forum Discussion
Putting zero value in blank field
- 5 years ago
Hi Vladimir_P ,
In most cases it would be expected to have blank value if data is missing or if we divide values with zero.
However, if you have business target to display these blanks as zeros, you can set it within IF statement.
Example:if(
isblank(
CALCULATE([Sales],SAMEPERIODLASTYEAR(tblDate[Date]),date)
)
,0
,CALCULATE([Sales],SAMEPERIODLASTYEAR(tblDate[Date]),date)
)
Cheers,
Nemanja Andic
Hi Vladimir_P ,
In most cases it would be expected to have blank value if data is missing or if we divide values with zero.
However, if you have business target to display these blanks as zeros, you can set it within IF statement.
Example:
if(
isblank(
CALCULATE([Sales],SAMEPERIODLASTYEAR(tblDate[Date]),date)
)
,0
,CALCULATE([Sales],SAMEPERIODLASTYEAR(tblDate[Date]),date)
)
Cheers,
Nemanja Andic
Hello nandic ,
Thank you very much! It works very well in my model 🙂
The essential thing was to present data in the field "Revenue difference". Before your solution, this was not possible. Thank you for that!
Have a nice day!
Vladimir