Forum Discussion
How to make a calculated column that calculates the difference between report dates
- 4 years ago
Daryn-TP , Try a measure like
Change % =
var _date = maxx(filter(allselected(Table), [Location] = max(Table[Location]) && Table[Date] < Max(Table[Date])), [Date]) //Use all('Table') if one date is selected
return
Sum(Table[Memory Size]) - calculate(Sum(Table[Memory Size]),filter(allselected(Table) , [Location] = max(Table[Location]) && Table[Date] = _date))use all in place allselected if needed
So thankyou for the response amitchandak
I tried the suggested DAX and I get an error message, "The function SUM cannot work with values of type String"
The dax I used is below. So in my actual datset the table is called "Virt-Data", DC=location, Meeting Date = Date. I substituted these terms into your suggested DAX.
Nevermind I figured it out I had one of my parameters set as an alphanumeric rather than a number. Thank you!