Fun problem, and I haven't yet 100% cracked it...
I can return the 2nd last date, with the days between (yellow) (MIN DATE) where not the same month
or I can return the 2nd last date with days between, but without the same month logic (pink) (MIN DATE 2), that's where I am stuck...
Days calc can be swapped when the MIN DATE works properly...
Thought id share (v9.2.4 attached) where I am, in case
a) its useful
b) someone else (cleverer than me!) can extend/ or replace to give you the full desired functionality...
Interested to see
201694.twbx 26.3 KB
Are you looking to output a different value for every date in your table, or do you just want something like the following:
Thank you very much! That's exactly what I want.
I can't open the workbook since Im using Tableau 9.0.
Would you mind to share the calculations?
One more question, is it possible to find out the result (value) without table calculation?
Your reply is very useful. I will keep working on your approach.