Forum Discussion
peffany
3 years agoFrequent Visitor
How to filter by oldest date
Hello there, I'd like to filter a card visual by the oldest date. It seems like the only options i'm given are filter by date intervals. Below I put a screenshot of the Filter pannel with two...
- 3 years ago
Ok, I should have tested that sorry, this is working for me:
Date filter = If(Calculate(FIRSTDATE('Total'[Date Livraison]),ALL('Total')) = FIRSTDATE('Total'[Date Livraison]),"TRUE","FALSE")Note I had to encase "TRUE" and "FALSE" in quotes, turning them into text for the measure to work.
- 3 years ago
Thanks for the rectification. I haven't tried your method as I've found an alternative one. I created a function column (not sure how you call it...) :
Color Alert =VAR today = TODAY()VAR alert_date = [Date Livraison]RETURNSWITCH(TRUE(),today > alert_date, "Red",BLANK())Thanks for your help. I do appreciate it.
halfglassdarkly
Responsive Resident
3 years agoOk, I should have tested that sorry, this is working for me:
Date filter =
If(Calculate(FIRSTDATE('Total'[Date Livraison]),ALL('Total')) = FIRSTDATE('Total'[Date Livraison]),"TRUE","FALSE")
Note I had to encase "TRUE" and "FALSE" in quotes, turning them into text for the measure to work.
peffany
3 years agoFrequent Visitor
Thanks for the rectification. I haven't tried your method as I've found an alternative one. I created a function column (not sure how you call it...) :
Color Alert =
VAR today = TODAY()
VAR alert_date = [Date Livraison]
RETURN
SWITCH(
TRUE(),
today > alert_date, "Red",
BLANK()
)
Thanks for your help. I do appreciate it.