Automatic task reminder pushed to Slack/Email

I did my homework. I searched for this topic and found several threads on this but none truly offers a simple solution. Can someone please talk to me like I’m 5? This is a simple thing elsewhere but it seems very complicated on Coda. I read that it involves a push button, a formula, and automation to push the formula. Can an expert lay out the steps with the formula (including which piece of info inside the formula that needs to be changed)
The steps:
1.
2.
3.
Thank you in advance. You are helping non-formula dummies like me in the community in a big way.

I don’t think you’d even need hand written formulas for that. You’d simply create a time based automation, that checks if a reminder should be sent and sends them if necessary. You’d use the Slack pack or an email pack like Gmail to send the reminder.

I hope this helps!


Tobias,
This is the part I don’t get. The automation clearly is asking for a formula.

Ah I see. You’d need a formula there.

I’ve created a test doc with an automation for this:

You can copy it into your workspace to see the automation.

Here the formula:

Tasks.Filter([Due Date] <= Today() AND Done = false)  // Only get the undone due and overdue tasks
  .ForEach(  // Go through all of them
    Notify(  // And send a notification
      CurrentValue.[Created by],  // To the creator of the task
      "Task due: " + CurrentValue.Name  // With the message "Task due: <task name>"
    )
  )

And you’d need to write that into the “Then” block instead into “If” (as shown in your screenshot).

2 Likes

Thank you Tobias,
It did run for me, kinda? It doesn’t run at the exact time of the Due Date. I guess it has to obey the “every hour” rule in the Time-based trigger right? Check out the setup I did based on your direction: https://coda.io/d/_ddDobkLFTJu/Auto-reminder_sutHo

I had to add “And Then” to run a Coda notification to the Owner in order to Test rule.

Can this be modified to run Tasks 2 table where Done is not based on True/False but on Status Selection?


If I don’t add “And Then” to run a Coda notification, nothing happens. When I do, the notification runs every hour even when the task is rescheduled or marked “Done”

1 Like

Hello Hung,

I believe one of the things you want to tweak is to replace the Today() with Now() in your formula. Today() is apparently pointing at the very beginning of the current day, so if all your tasks have Due Date set somewhere to the middle of today, then it makes sense no notification is sent yet: after all, your current formula targets all the rows with Due Date earlier than the beginning (00:00) of the current day. There are no such rows.

I expect that from tomorrow (6/17) the formula will start sending notifications as expected. And if you replace “Today()” with “Now()” in your formula, notifications should start to be sent from the next automation run (so, hourly).

If you want to run reminder for Tasks 2 table based on Status Selection, I think you can just tweak your formula to something like

   [Tasks 2].Filter([Due Date] <= Now() AND Status != "Done")

or

[Tasks 2].Filter([Due Date] <= Now() AND Not(Status.In("Done", "In progress")))

…if you want to exclude multiple statuses.

Is it helpful to you?

Cheers,
Piotr

1 Like

Hi Piotr,
Thank you for your help. I get a Formula issue when I swapped the - AND Status != “Done”) part in. See attached.

Might be a copy-paste issue here. The quote marks on your screenshot look suspicious to me. Could it be that you pasted “Done” fragment from this forum post instead of writing it from scratch in Coda formula editor?

There is a slight difference in the quote mark I see in my Docs (left one below) vs what I see in your screenshot (right one below):
image

Hello Tobias and Piotr,
Thank you for your help on this. I got both methods working well. To help others, I have outlined the two methods below:

Auto-reminder via automation with Done as a checkbox:

  1. Set up a task table with Name, Due Date, Created By, and Done (as checkbox column)
  2. Go to Document settings and select Automations
  3. Add Rule
  4. For “When”, Select a time-based trigger and set the Repeat on to your liking. Expiration is set to Never ends
  5. In “Then”, click on f for formula and enter the following:

Tasks.Filter([Due Date] <= Now() AND Done = false) // Only get the undone due and overdue tasks
.ForEach( // Go through all of them
Notify( // And send a notification
CurrentValue.[Created By], // To the creator of the task
"Task due: " + CurrentValue.Name // With the message “Task due: ”
)
)


Auto-reminder via automation with Done being a status selection
Follow all steps 1 to 4
5. In “Then”, click on f for formula and enter the following:

[Tasks 2].Filter([Due Date] <= Now() AND Status != “Done”) // Only get the undone due and overdue tasks
.ForEach( // Go through all of them
Notify( // And send a notification
CurrentValue.Owner, // To the creator of the task
"Task due: " + CurrentValue.Name // With the message “Task due: ”
)
)

Notes:

  • When copy/paste the formula, the quotation marks will default into the writing style, so make sure to retype the “Done” inside the formula window.
  • Column names like Tasks, Due Date, Created by or Owner have to match in the formulas for this to work.
2 Likes

Hey @Hung_Le you can also accomplish this with a simpler automation and almost zero formulas. Here’s how!

Loom video:

(Note, I commented on the video above, as I made an error on the button logic… you need an OR not an AND. The doc below reflects that change.)

Doc to copy: https://coda.io/d/_dIWw0JL8C0E/Simpler-Setup_sug5T

2 Likes

@Steve_Simon2 - Thank you so much for this. I’m been OOO so I haven’t had the chance to review. It’s super helpful. It’s prob the best explanation of how to embed push buttons for my question I have seen. I assume that I can use the same logic here to send a team message to celebrate holidays and birthdays, correct?

Yeah this pattern of embedding disable logic on the button is broadly re-usable. For birthdays, if you had a table of users, where each row had their birthday, you could disable buttons to send a birthday message when today() != BirthDateColumn and set your automation to trigger daily on that button column.

1 Like