Search code examples
filterpowerbidaxslicers

Trying to return the maximum value of a filtered date column in Power BI


I have a table within Power BI that has a date field, and a value field. I am filtering on this date field, using a slicer, to sum all of the value data before the specified date. I would like to get this date value to use in a LOOKUPVALUE() elsewhere (to get a conversion rate).

Is there a way to accomplish this?

I have tried the DAX functions that return the values of a particular table/column with filters preserved but this never seems to work, and just returns the entire dataset, e.g. VALUES(), FILTERS(), ALLEXCEPT().

Any help would be greatly appreciated!


Solution

  • I found a solution using measures.

    The DAX for future reference:

    Filter Date = CALCULATE(MAX('Table'[Date]),ALLSELECTED('Table'))