Forum Discussion
Filter on the measure.
Anonymous These Measure give Year and Previous Year and Year on Year Change and Year On Year %
Add the Year Slicer and then select at least 2 consective years!
Max Year = CALCULATE([Total Net], FILTER(Payments, Payments[PMT Year]=MAX(Payments[PMT Year])))
Max Year -1 = CALCULATE([Total Net], FILTER(Payments, Payments[PMT Year]=MAX(Payments[PMT Year])-1))
YoY Change = [Max Year] - [Max Year -1]
YoY % Change = DiVIDE ( [YoY Change], [Max Year -1], 0)
Let me know if you do decide to add a Caledar Table - there's a better way to do this.
I tried the following expression and the value is blank:
Consumption Warehouse 2 = calculate (sum (Facts [Vl_ConsumoAlmox]) - sum (Facts [Vl_EstornoAlmox]), FILTER (DMEGF_Ano; DMEGF_Ano [Year] = MAX (DMEGF_Ano [Year]) - MAX (DMEGF_Ano [Year]) - 1))
- Sean10 years ago
Community Champion
Anonymous
2016 - ( 2016 - 1) => 1
FILTER (DMEGF_Ano; DMEGF_Ano [Year] = MAX (DMEGF_Ano [Year]) - (MAX (DMEGF_Ano [Year]) - 1)))
delete the underlined part
- Sean10 years ago
Community Champion
are you using DMEFG_Ano[Year] for the Slicer?
- Sean10 years ago
Community Champion
Anonymous what are you trying to calculate? for what year?
this is what your FILTER is doing => 2016 - 2016 - 1
thats why you are getting BLANK
- Greg_Deckler10 years ago
Community Champion
Consumption Warehouse 2 = calculate (sum (Facts [Vl_ConsumoAlmox]) - sum (Facts [Vl_EstornoAlmox]), FILTER (DMEGF_Ano; DMEGF_Ano [Year] = (MAX (DMEGF_Ano [Year]) - 1)))
- Anonymous10 years agoNot applicable
correct the error and the information is being displayed however when I do a filter annually whether in 2016, 2015 or 2014 values are blank
- Anonymous10 years agoNot applicable
yes, to correct that what you recommend? I create a dimenssão calendar?
- Sean10 years ago
Community Champion
Do you have any other filters/slicers ON at the same time?
EDIT:
If you want to create a Date Table look here (Link by Matt)
http://www.powerpivotpro.com/2015/02/create-a-custom-calendar-in-power-query/
- Anonymous10 years agoNot applicable
Yes, my reports have several filters
- Sean10 years ago
Community Champion
Anonymous I tried these formulas with several Slicers and it works.