Forum Discussion
Anonymous
6 years agoNot applicable
Total problem with SAMEPERIODLASTYEAR
I have been struggling for some time now with this small&easy(?) problem.. ☹️ Measure: Diff sales between years = IF ( ISBLANK([Total sales last year]); BLANK(); [Total sales (SU...
- 6 years ago
Hi , Anonymous
Not very clear .
Maybe what you need is a formula like this:2Diff sales between years = SUMX(DISTINCT('Date'[Date]), IF ( ISBLANK([Total sales last year]), BLANK(), [Total sales] - [Total sales last year] ))Here is a demo.
Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
v-easonf-msft
6 years agoCommunity Support
Hi , Anonymous
Not very clear .
Maybe what you need is a formula like this:
2Diff sales between years = SUMX(DISTINCT('Date'[Date]),
IF (
ISBLANK([Total sales last year]),
BLANK(),
[Total sales] - [Total sales last year]
))Here is a demo.
Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
6 years agoNot applicable
Thanks!
This is working!
But I will need some time to really understand how it works. 🤗
(I have only been working with PBI for few months.)