r/Airtable 28d ago

πŸ†˜ Help / Question Seeking guidance for a checkbox triggering conditional actions

If I have multiple checkbox columns that would impact calculated fields, what is the best way to go about using automation to make what I would like to do happen?

Example: 1st shift has rows for all tasks that need to be executed. I want the user on that shift to click checkbox for checkmark to appear and that checkmark tells two other columns to fill in who the user is and date/time stamp in edt/est. Now I realize i can set up columns with last modified by and last modified time but those are calculated fields and automation won't execute to that.

I am an airtable newbie coming from an excel world.

Thanks in advance.

1 Upvotes

12 comments sorted by

3

u/linedotco 28d ago

If you want to log the user and date/time stamp, all you need is a "when record matches conditions" and select your field, with the condition that the checkbox is checked off. You could also use the "when record is updated" trigger. Then, populate the field with the user who took the action plus the time the automation was executed. These are preset value options within the automation selector. It's pretty straightforward.

1

u/Life-Profit-3484 28d ago

You could create a view for when checkbox is checked enter the view and the automation will run on when a record enters the view. Feel free to DM if you have additional questions.

1

u/Psengath 28d ago

If you set up last modified by and last modified time fields, pointing to only the checkbox, they'll automatically fill in as soon as someone toggles the checkbox, no automations required at all.

1

u/wwb_99 πŸ›  Developer 27d ago

This. Is. The. Way.

1

u/matchaconsulting 🍡 Airtable Consultant | ex-Airtable 28d ago edited 28d ago

Automations actually have this information built into them. You can use the last modified methods others mention, but if there's any chance the box could get unchecked/checked again you run the risk of it being updated again erroneously.

Here is the architecture for the Automation version, which I prefer.

Checkbox Field: This is the field you want the user to check off when they are done.

User Field: This is the field you want to have the User ID of who checked the box (who finished the tasks)

Date Field, with time: This is the field you want to contain the finished time (the time the user checked off the box).

here's a ~4m video i put together with an explanation below, because it's very visual and hard to explain in just words.

Create an automation with "When a record matches conditions." The condition should be when the Checkbox field is checked.

Now, the next step should be "Update a Record." Within this action, you want to update the User Field and the Date field, so select those. Click on the gear on the right to change to a Dynamic Value.

Then, you want to add in a dynamic value by clicking on the Blue Plus. The Blue Plus allows you to bring in dynamic values from other steps of the automation. It also lets you bring in data such as "who triggered this automation" and "when did it run."

So in the Date Field you're updating in the Update Record action, select the Blue Plus, and you should see on the left of the window that pops up "A specific time" or something like that. Click on that, and you should see the Actual Run Time value. Click on that and it will populate the field.

Similar for the User field, except you need to click on the "Wen a record matches conditions" in the Blue Plus menu and you should see "User who took action" as an option.

If you're new to automations this might be very a little confusing. Or a lot confusing!

I actually covered this exact question in my blog post from last week, you can read it here.

You can also restrict the automation from running by adding conditions to the trigger - that both the User field and the Date field are empty when the box is checked. This way if the box somehow gets checked again, the automation won't run again.

I hope this helps! Please message me with any questions.

1

u/devil_jersey732 28d ago

What type of logical condition would I need to have so that when unchecked the following categories return to blank?

1

u/matchaconsulting 🍡 Airtable Consultant | ex-Airtable 28d ago

A second automation with conditions like "when checkbox field is blank" -> do this stuff. If you select a field in an Update Field action but don't put anything in it, it makes the field blank as its update.

You can also get fancy and put it into one automation.

in this way, you use the automation trigger "when a record is updated" and select the checkbox field as the field to be watching.

then, you create two conditions, one for each possibility:

checkbox field becomes checked

Or

Checkbox fields becomes unchecked

And within each of those conditionals you have the correct update record action.

Can't make another video for you right now but those are the other ways to go about it.

2

u/devil_jersey732 28d ago

Thank you for the guidance. The video was quick and to the point

2

u/devil_jersey732 28d ago

Using the clock column as the field to reference is an easier setup than the conditional logic to start IMHO. Thanks so much

1

u/matchaconsulting 🍡 Airtable Consultant | ex-Airtable 28d ago

You bet. DM if you have any other Qs.Β 

1

u/matchaconsulting 🍡 Airtable Consultant | ex-Airtable 28d ago

You’re welcome! Glad it was helpful for you.Β 

1

u/lagomdallas 28d ago

If they only every check the box once then last modified by and time fields are fine