Forum Discussion
NeilL
7 years agoFrequent Visitor
Need Help With DAX Filtering
Hello All, I am new to DAX and am stuck. I don't quite understand the FILTER() function which is, I think, the reason I am stuck. I have two tables, Dates & Forecast, which are joined on a fiel...
- Anonymous7 years ago
NeilL -
You could modify the calculation like the following:
Running Total = var maxForecastDateInContext = MAX(Forecast[Date]) var lastDateInContext = MAX('Date'[Date]) var lastRelevantDate = MIN(lastDateInContext, maxSalesDate) return CALCULATE( SUM('Forecast'[Revenue]), 'Date'[Date] <= lastRelevantDate )Hope this Helps,
Nathan
Anonymous
7 years agoNot applicable
NeilL -
You could modify the calculation like the following:
Running Total =
var maxForecastDateInContext = MAX(Forecast[Date])
var lastDateInContext = MAX('Date'[Date])
var lastRelevantDate = MIN(lastDateInContext, maxSalesDate)
return CALCULATE(
SUM('Forecast'[Revenue]),
'Date'[Date] <= lastRelevantDate
)Hope this Helps,
Nathan
NeilL
7 years agoFrequent Visitor
Anonymous That solved my problem! Thank you for the speedy reply and helping me solve my issue!