By Alex Sherwood aka aNotioneer
<aside> 👋 This guide explains how to check whether a date is today, within X days or overdue, to highlight that info in a calendar of birthdays in this instance.
Notes starting with 💡 explain how a formula function works in Notion and notes starting with 📝 explain how a particular formula that I've created works.
If you have any questions, please feel free to add a comment or ask them here.
</aside>
Contents
<aside> 🚨 If you get an error message about a ‘syntax error’ when copying and pasting these formulas, try copying the ‘Unformatted formula’ from the toggle list instead.
</aside>
💡 This formula will tell you that a date is 0 days away if it's tomorrow, 1 day away if it's the day after tomorrow etc. If you reverse the order of the dates that you're comparing then the formula will give you -1, rather than 1.
dateBetween(prop("Birthday"), now(), "days")
if(and( dateBetween(prop("Birthday"), now(), "days") <= 29, dateBetween(prop("Birthday"), now(), "days") >= 0), "🔜", "")