Hello everyone,
I have an issue on a set analysis date selection, I want to select the penultimate date available. It only works without any filters applied, but it stops working when a different date is selected. The expression goes like:
=COUNT({< [DATE]={'$(=MAX(DATE,2))'}>}operation_id)
PD: it works perfectly (with and without filters) when looking for actual date (max(date))
Thanks!
All it is doing is to look at the Max Date which is less than the Max date selected
=Max({<DATE = {[<$(=Max(DATE))]}>}DATE)
So, the inner set analysis is saying look at all DATEs less than Max(DATE)...So, Max date less then the actual max(DATE) will be your second max date.. you can also use this
=Max({<DATE = {[<=$(=Max(DATE))]}>}DATE, 2)
Now, I added <=... so to find the second max date, you will need to add the 2 at the end....
Very useful !