Script in automation : creating multiple records with a form

Hi there,

I’m a French PharmD and I use Airtable to manage all patients’ appointments.
It’s very useful for all my team except 1 laborious step : create appointments.
I manage all appointments in a dedicated table (every X days I create X records for next days, so anyone can select a slot). So far I create appointments (1 appointment = 1 record) one by one.

Ideally, I would like to fill a form and create multiple records with an automated script.

For exemple, if I fill a form with :

  • from : 22/10/2022 09:00
  • to : 22/10/2022 11:45
  • every : 00:15 (fifteen minutes)

==> It run a script and create records :
22/10/2022 09:00
22/10/2022 09:15
22/10/2022 09:30

22/10/2022 11:45

As a Pharmacist I don’t have skills to create a reliable JavaScript code in automation.

Any help would be grateful ! :slight_smile:

Thank you,


you could use autonumber and formula DATEADD({Somedate}, 15*num, ‘minute’), with 'duplicate record" and/or copy/paste to achieve your goal.
Also, you can add formula field DATEADD({From}, '{every}, ‘minute’) and create automation, which will create new record each time when record matches condition {From}<{To} and put result of a formula to field {From}. Thus, it will create new and new records with a step ({every} should be a number or duration maybe) , until {From} reaches {To}.
(regarding {From}<{To} - i mean functions IS_BEFORE, IS_AFTER. Usually I don’t need to use time functions, so I don’t remember right syntax)

Salut @Hadrien_Vuillet-A-Ci, the use case you’re describing sounds fairly straightforward.

Based on the info you shared, an automation is ostensibly the best way to go about this, both in terms of near-term benefits and beyond. Although tying a recurring automation to a form that you still need to fill out manually is probably not the best approach here, even though it would still alleviate the inconvenience of your current workflow.

But assuming your monthly appointments are in the hundreds, or even low thousands, the $20 Pro plan comes with more than enough computing resources to have a base that updates in real-time with minimal involvement on your end.

This kind of undertaking is definitely within reach of any moderately motivated individual; Alexey already outlined how you could achieve it without so much as glancing at any actual code. But your first instinct was correct: JavaScript is, generally speaking, the best tool for the vast majority of Airtable-powered and -adjacent development.

While your circumstances naturally aren’t as favorable if you’re just starting out, coding custom behaviors tends to be faster than describing complex logic via blocks and web forms. And its results tend to be easier to both maintain and scale. Dareisay this seems like a great project for a JS newcomer due to its narrow scope.

That said, I’m guessing most healthcare professionals can think of better ways to spend their sparse downtime. If you’re one of them, the good news is that you woon’t have any trouble commissioning someone who’s willing and able to handle this quickly and affordably. You could try posting on the Hire a Consultant board or contact someone via the recently launched Airtable Consultant Directory. Feel free to DM me for a quote, as well.

P.S. In case you do decide to tackle this yourself, returning to these boards with detailed questions about any technical difficulties you encounter is a great way to fast-track the learning process with minimal frustrations. That, and reading Airtable’s super-comprehensive documentation.

Hi Alexey,

Thank you so much, your solution is very elegant !

Let me just inform readers that I had to replace the step “when record matches condition {From}<{To}” (because we can not select a dynamic value for time conditions) by another one "when record matches condition {Condition to run automation} = “Go”}, which include that I had to create a formula field {Condition to run automation} : IF(From < To, "Go", "Stop").

Again, thank you so much.


1 Like

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