Help

Post automated email - How to Update Date / Time of Record

Topic Labels: Automations Formulas Sync
207 2
cancel
Showing results for 
Search instead for 
Did you mean: 
galeri
4 - Data Explorer
4 - Data Explorer

Hi, 

I have managed to set up an email automation. But after the email is sent, I want to update the AirTable record with the date and time the email was sent. 

How do we do this? I did see Kuovonne do this with a custom script in another example. But not sure how to do this for us. 

@kuovonne 

Thank you. 

2 Replies 2
Pascal_Gallais-
6 - Interface Innovator
6 - Interface Innovator

Hello,

There is a way to do that without having to manage a script.

-1- Create a table with just 2 fields and 1 record:

Pascal_Gallais_0-1720105554361.png

Field date_id is an integer 

Field current_date is the formula NOW()

-2- Add a "Find records" action in your automation that you link to the table "date" with the condition date_id = 1:

Pascal_Gallais_1-1720105729399.png

-3- Add a last action in your automation to update the record that triggered the automation:

Pascal_Gallais_2-1720105841828.png

The value to pass to field "Mail sent" comes from the "Find records" action.

You could also create the formula field NOW() in the table you want to update, but it is not a good idea because this formula will slow down you database if called on too many lines. This is why I suggest to create a dedicated table with a single record.

Regards,

Pascal

I use a very simple automation script that outputs the current time. Then I use that output in an update records action. I include this script in my automation helpers, or if you do not have budget, you may be able to find a free version. 

I don't recommend using a formula field with NOW(), not even with a single record in a helper table. Even if there are few enough records to affect base speed, NOW() also is notoriously inaccurate. It can be off by anywhere from a few minutes to a few hours, depending on when the base and the table were last viewed/accessed.