I have been creating a dashboard in which I am trying to showing current Selected year vs last year analysis. Please see the below image :
As you see in the above image, 2020 year selected from the slicer and 2020 sales is 4.30M. Expectation : I want to show the last year difference with Arrow sign means if the current year sales is greater than last year than "Green upper arrow" and if the last year sales greater than current year then "Red down arrow".
Thing I Tried : I have created a DAX, but it not showing any value to me : Previous Year Sales = CALCULATE(sum(Orders[Sales]),PREVIOUSYEAR(Orders[Order Date]))
Option 2 : I have also tried this one (it show me value but desired results):
same period last year = CALCULATE(Sum(Orders[Sales]),SAMEPERIODLASTYEAR(Orders[Order Date]))
Expected Output ( Current Year vs last year percentage with Arrow sign) :
Sample data link : http://www.cse.ohio-state.edu/~hwshen/Melbourne/Data/Superstore.xlsx How can I achieve the above ?
Thanks