More than a year after posting Events and anniversaries - Help - Obsidian Forum, I found the solution, and I thought I’d share.
In my notes I use a tag “contact” for some people, and I have a dates property with a list of things I’d like to remember about them. I use the format:
dates:
- "2023-06-01: Start looking for a way to retrieve dates"
- "2024-07-18: Found the solution, and I'm going to celebrate every year"
- "1980-03-05: Birthday"
In a “Reminders” note, I use the following dataview queries to help me see reminders for today and this week.
Reminders for today
LIST
event
FROM
#contact
WHERE
contains(file.frontmatter, "dates")
FLATTEN
dates AS reminder
FLATTEN
date(split(reminder, ": ")[0])
AS
date
WHERE
dateformat(date, "MM-dd") >= dateformat(date(now), "MM-dd")
AND
dateformat(date, "MM-dd") <= dateformat(date(now), "MM-dd")
FLATTEN
split(reminder, ": ")[1] + " (" + dateformat(date, "d MMM") + ", " + durationformat(date(now) - date, "y") + ")"
AS
event
SORT
dateformat(date, "MM-dd") asc
Reminders for this week
LIST
event
FROM
#contact
WHERE
contains(file.frontmatter, "dates")
FLATTEN
dates AS reminder
FLATTEN
date(split(reminder, ": ")[0]) AS date
WHERE
dateformat(date, "MM-dd") >= dateformat(date(sow), "MM-dd")
AND
dateformat(date, "MM-dd") <= dateformat(date(eow), "MM-dd")
FLATTEN
split(reminder, ": ")[1] AS event_note
FLATTEN
dateformat(date, "d MMM") AS event_date
FLATTEN
durationformat(date(eow) - date, "y") AS event_age
FLATTEN
event_note + " (" + event_date + ", " + event_age + ")" AS event
SORT
event_age DESC
SORT
dateformat(date, "MM-dd") ASC
Hopefully it helps someone else, too!