# Backend Workflow & Dates

**URL:** <https://forum.bubble.io/t/backend-workflow-dates/361614>\
**Category:** Database\
**Created:** [March 2, 2025, 3:02am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614 "2025-03-02T03:02:37Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![ddiaz](https://avatars.discourse-cdn.com/v4/letter/d/ee59a6/32.png) [@ddiaz](https://forum.bubble.io/u/ddiaz)\
**Post date:** [March 2, 2025, 3:02am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/1 "2025-03-02T03:02:37Z")

</div>

Hi Bubblers, I’ve tried for quite some time to figure this out myself and reading through the forum but haven’t been able to come across the solution (apologies if it is hidden in plain site).

I am building a training database for my company and want to be able to send an email when the expiry date (a field on the training record) is within 60 days of the current date / time.

The only solution I can see is that when the record is created, an API is scheduled on that specific record to send the email when it is 60 days out from the original expiry. However, I thought there may be a simpler solution that just monitors the database and will email as the record gets to that date (similar to a change in database trigger).

Any help or advice would be extremely appreciated.

---

<div class="post-metadata">

**Author:** ![mitchbaylis](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/mitchbaylis/32/122860_2.png) [@mitchbaylis](https://forum.bubble.io/u/mitchbaylis)\
**Post date:** [March 2, 2025, 3:12am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/2 "2025-03-02T03:12:43Z")

</div>

you could set a daily recurring workflow to check for records where expiry date \> current date round down to date and expiry date is \< current date rounded down to date + 1 day

this will match records from midnight to midnight for a 24 hr period

---

<div class="post-metadata">

**Author:** ![ddiaz](https://avatars.discourse-cdn.com/v4/letter/d/ee59a6/32.png) [@ddiaz](https://forum.bubble.io/u/ddiaz)\
**Post date:** [March 2, 2025, 3:40am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/3 "2025-03-02T03:40:28Z")

</div>

Thank you!! Great idea, do you know how to set it to do that? This is what I’ve done based on what you mentioned… Not sure if this is right?

Below is the API workflow trigger

 ![Screenshot 2025-03-02 at 1.38.15 pm](https://us1.discourse-cdn.com/bubble/original/3X/c/b/cb425ee62e858f52d6e1ba077f71c278f832ffe8.png)

This triggers a API workflow on a list that then sends an email using this info data? Or is it much simpler than that?

Also - if this is done daily, will it send an email every single day until they update it (just thinking that may be annoying for people, perhaps the rule needs to be = -60 days, instead of greater than as it would send every day I assume until they change that?

---

<div class="post-metadata">

**Author:** ![mitchbaylis](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/mitchbaylis/32/122860_2.png) [@mitchbaylis](https://forum.bubble.io/u/mitchbaylis)\
**Post date:** [March 3, 2025, 1:44am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/4 "2025-03-03T01:44:29Z")

</div>

you need to use a 24 hr time window like I mentioned above

greater than and less than combined

you can’t use = unless you store the dates as midnight and then compare them to a date at midnight

normally I set a [make.com](http://make.com) scenario to ping the backend workflow daily. I just find that the easiest way to do it.

---

<div class="post-metadata">

**Author:** ![boston85719](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/boston85719/32/77286_2.png) [@boston85719](https://forum.bubble.io/u/boston85719)\
**Post date:** [March 3, 2025, 3:43am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/5 "2025-03-03T03:43:26Z")

</div>

Don’t do a daily recurring event…it is a waste of WUs and unnecessary. Your first thought to schedule is the correct thought so do that. And if you think for some reason the date might change after creation ensure you save original scheduled workflows I’d and cancel it when scheduling new expiration date workflow.

---

<div class="post-metadata">

**Author:** ![ddiaz](https://avatars.discourse-cdn.com/v4/letter/d/ee59a6/32.png) [@ddiaz](https://forum.bubble.io/u/ddiaz)\
**Post date:** [March 6, 2025, 1:32am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/6 "2025-03-06T01:32:04Z")

</div>

Thanks @boston85719 . Curious to know what the difference in WUs would be, is it quite significant. Looking for a simple solution, and thought running on a list would be better - if WUs are higher daily, perhaps this should be just once a month sent out.

---

<div class="post-metadata">

**Author:** ![boston85719](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/boston85719/32/77286_2.png) [@boston85719](https://forum.bubble.io/u/boston85719)\
**Post date:** [March 6, 2025, 3:11am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/7 "2025-03-06T03:11:53Z")

</div>

Difference would be the cost of searching everyday versus not plus some more WU consumption costs like triggering actions

---

<div class="post-metadata">

**Author:** ![ddiaz](https://avatars.discourse-cdn.com/v4/letter/d/ee59a6/32.png) [@ddiaz](https://forum.bubble.io/u/ddiaz)\
**Post date:** [March 13, 2025, 7:25am UTC](https://forum.bubble.io/t/backend-workflow-dates/361614/8 "2025-03-13T07:25:57Z")

</div>

Thank you @boston85719 and @mitchbaylis , I’ll play around with the two options to see what works best. Appreciate both our feedback.
