Forum Discussion
Year over Year calculation
- 9 years ago
Hello,
To Visits
SumVisits= Calculate([Sum(Table[Visits]))
VisitLastYear= Calculate([SumVisits],DATEADD(Table[Date],-1,YEAR))
YoYVisits = [SumVisits]/[VisitLastyear]-1
To PageViews only change Visits column to Page Views Column.
Hello,
I am relatively new to Power BI so I'm still fumbling through it. I have attempted to use this technique in a report and continue to have an issue. As far as I can tell I have followed the steps outlined here. I should be seeing 2015 results in the RevLastYear column next to 2016 but instead only get the Total 30107315 and that is only because I turned on Total row otherwise I have a blank RevLastYear column. I hope I provided enough information to give you an idea of what I'm up against here. Do you think you can help?
Year = YEAR(Shipments[Date])
DateMonth = MONTH(Shipments[Date])
SumRevenue = CALCULATE(SUM(Shipments[Total Revenue]))
RevLastYear = CALCULATE([SumRevenue],DATEADD(DATESYTD(Shipments[Date]),-1,YEAR))
Facing the same issue... I am working on DAX in Excel Powerpivot
All the measures are created in table Calculation_Cube.
TotalUnits= SUM(Calculation_Cube[Units])
1 -> Total_Units_Previous_Year=calculate([Total Units],SAMEPERIODLASTYEAR(DateTable[Date])) - If i choose this I am eding up getting same values as in 'TotalUnits'
2 -> Units Previous Year=calculate([Total Units],SAMEPERIODLASTYEAR(Calculation_Cube[DateValue])) - If i choose this I am ending up with all blank.
I also tried using DATEADD function with -1 for 'Year' Interval. It leads to the same 2 issues pointed above. Please help.
YOY Calculation Issue in PowerPivot DAX