Help

Field validation / Adjustment of an automation

Topic Labels: Automations
Solved
Jump to Solution
85 5
cancel
Showing results for 
Search instead for 
Did you mean: 
mirkolando
6 - Interface Innovator
6 - Interface Innovator

Hello community,

 

I have an automation that informs the user by e-mail if the deadline of a task is before the start date. Unfortunately, in my opinion, it is not possible to set a dynamic validation for fields that would prevent this.

However, if the user wants to move the timeline for the task, he usually changes the start date first and then the due date. this triggers the automation.

 

Does anyone have an idea how to prevent this?

 

best regards

Mirko

1 Solution

Accepted Solutions
TheTimeSavingCo
18 - Pluto
18 - Pluto

Hmm the main thing we're trying to do here is only run the automation after the user has finished keying stuff in, so I reckon you could try:

1. Make the automation run once a day and look for records that have a end date before the start date, then send an email for each of these
2. Create a formula field that calculates how long it's been since either of those fields have been updated, and if it's been at least 5 minutes and the end date is before the start date, trigger the automation
  - This requires you to use NOW(), which may make your base a bit laggy if you've got a lot of records.  Note that NOW() also has an update time of 5-15 minutes and is not accurate to the second, so there'll still be some delay before an email gets sent out with this method

See Solution in Thread

5 Replies 5

Hey @mirkolando

Let's do it step by step sharing my best practices for this case. 

Please create a formula field that will display the message "Dates correct" or "Deadline should be before the {start date}". This saves you the runs for one automation, and actually, you don't need this automation! User can update their input right on the interface. 

Did you try this solution? 

Thanks 
Dimitris Goudis

 

 

TheTimeSavingCo
18 - Pluto
18 - Pluto

Hmm the main thing we're trying to do here is only run the automation after the user has finished keying stuff in, so I reckon you could try:

1. Make the automation run once a day and look for records that have a end date before the start date, then send an email for each of these
2. Create a formula field that calculates how long it's been since either of those fields have been updated, and if it's been at least 5 minutes and the end date is before the start date, trigger the automation
  - This requires you to use NOW(), which may make your base a bit laggy if you've got a lot of records.  Note that NOW() also has an update time of 5-15 minutes and is not accurate to the second, so there'll still be some delay before an email gets sent out with this method

Hi
Please clarify the context.
I don't remember possible ways of interface forms validation, but even in old form view you can use workaround to deny submit for such records. Add conditional (when deadline is before start) single select with no options and mark as mandatory filled. Add good description.
When you can't construct condition with built-in elements, do it by formula field, then check for OK/notOK

There are several possible ways to react on moving start after deadline. It depends on what is allowed for user
- Set start date to be record creation date.
- Let user change start date and duration (days). Make duration a number, disallow negative numbers.
- Add formula to display user that such value is 'Invalid Deadline📆' (use emojii to make warning better visible)
- Add duration formula, add hidden field 'default duration' filled at starting point. If duration became negative, move deadline to a point where duration is equal to default.

ScottWorld
18 - Pluto
18 - Pluto

@mirkolando 

Airtable does not support field validations outside of a few validations on interface forms.

So if you want to get Airtable's limited validations, you could only do this if you are creating brand new records through an interface form.

For editing existing records, you can create a formula field to let people know if they have successfully passed the field validation or not.

Also, when creating brand new records through a form, you can get many more advanced field validations by using Fillout's advanced forms for Airtable instead of Airtable's native forms.

Hope this helps! If you’d like to hire an expert Airtable consultant to help you with anything Airtable-related, please feel free to contact me through my website: Airtable consultant — ScottWorld

mirkolando
6 - Interface Innovator
6 - Interface Innovator

@TheTimeSavingCo this worked well for the mails. Thank you 

@Dimitris_Goudis good idea, thanks a lot!

mirkolando_0-1732691974573.png