Automation to Update multiple records and link to Trigger Records

I am trying to update multiple records at once using an automation with a script. I received a lot of help by using the script referenced here: Update Multiple Records with Automation.

Basically, I am trying to mark records in one table (called “Summer Registrations”) as “paid” AND link those records to the the trigger payment record. The trigger payments can be linked to more than one record, which is why I know I need to use a script.

Marking all the found records as “paid” is working fine, but the problem I’m having is pulling in the Record IDs from the trigger step. In the screenshot, I want to put the Airtable record ID from the step1 trigger into the field marked “Receipt”.

hi @Tim_Ha,
To achieve what you want you need to change like 7 to say:
"Receipt": [{id : config.step1}]

This is because linked record fields (as I believe you set your Receipt field to be) are arrays of id-value pairs. So you need to add the id value paid which is {id : config.step1} (this is your id and your payment record id) and add it in an array so the field required format is respected.

Hope this helps!

Website: alessiomonino.com
Calendly: Calendly - Alessio Monino
Email: alessio.monino@gmail.com

1 Like

Hi Alessio_Monino,

That is exactly what I was looking for! I had figured out a way to link the records by using a second automation which triggered when the payment status was changed, but your solution saves me from having to do that. I really appreciate the help!

1 Like

This topic was solved and automatically closed 3 days after the last reply. New replies are no longer allowed.