Skip to main content

Hi everyone, 

I’m new to using Script in airtable and was using ChatGPT to help me write my script. Basically, I want the script to read my table (titel is Workshop registration) and when people register, they can click on as many workshops as they want. The script was to then separate the 1 registration into multiple, and it worked! However, I changed one of the columns from single to multi-select and it messed everything up, including the set up. It also just started to bug out a lot. Do you guys know what I could do? I’m not a coder at all and was primarily using ChatGPT to help me write it. 

I can help you with the script. I’ll need to review your script first. You can reach out to me with more details via email.

Taha, Airtable Advisor.


Hm, could you provide screenshots of your tables and data and the script itself?


@dzass 

How are people registering for your workshops?

If you simply provide them with an Airtable form (or a Fillout form) to register, you wouldn’t need to do any scripting nor automations at all.

You would just need to switch your workshops field to become a linked record field instead of a multi-select field.

Then, when the form is submitted, all of the linked records would automatically appear in their own table — linked to the original record in the original table.

If you decide to stick with a multi-select field (which is not recommended), then you would be required to create an automation to loop through the selected workshops to create new attendance records for each selection. But again, this is not recommended because it is not proper database structure.

While your form can be setup natively with Airtable’s forms, you can gain significantly more features & power by using Fillout, which is 100% free,

I show how to use a few of the advanced features of Fillout on these 2 Airtable podcast episodes:

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


Hey ​@dzass!

I would suggest that if you can get this solved without code, you stick to the no-code solution.

First: I would suggest using Fillout as mentioned by Scott (more on the difference between Fillout and Airtable native forms here).

Second: You can build a similar workflow (iterating and creating multiple records given certain values) using Make, or N8N rather than a script on Airtable! -for more info on these automation tools you can check out this other article.

In short, you might be better off sticking with something that you can fully understand. -or of course you can spend a lot of time fighting with ChatGPT which of course I sometimes do as well :D 

Hope this helps!

Mike, Consultant @ Automatic Nation


Hi ​@dzass!

 

That’s a great question! I don’t think you necessarily need a script to separate registrations. Here’s my solution that makes use of Airtable’s native forms (you don’t need Fillout!)

 

 

As you can see in the gif, you will be able to select as many workshops as you want in the form. An automation runs in the background to split the form responses into multiple “registrations”.

 

Instead of using a script, I used an automation to to loop through the “workshops” response in the form to create new records:

 

Here’s my example base, feel free to have a look and reference the automation and form included:
https://airtable.com/invite/l?inviteId=invdfeyzttk1fENAm&inviteToken=48e860372abcb74e9e83fb2559e6091febbb24db044453cd5f839fe24e0bc461&utm_medium=email&utm_source=product_team&utm_content=transactional-alerts

 

 

As Scott has mentioned, there is value in using linked record field instead of a multi-select field. I’m happy to talk more this set-up if you’re interested :D

 

Happy building!

 

Bryan

 

 


Reply