I’m importing some records of clients via csv. One column in the csv contains multiple appointment dates per client.
I want the clients to go into my Clients form. The Clients form has a Link to Form field called Appointments. It’s a 1:M field and “Show Inverse Relationship” is checked.
I need the clients to be imported as records in the Clients form, and the multiple dates per client from the csv to be entered as child records in the Appointments form.
I don’t think there’s a way to do that all in import, so I figured I’d:
1. Import the csv into Clients, while creating a new field “Dates to Process” to capture the multiple appointment dates
2. Use a script to loop through “Dates to Process” and create the appropriate records in Appointments
For step 2, I’m pretty sure I can loop through the “Dates to Process”, but I don’t know how to apply each date as a new record in “Appointments” that’s associated with that client in the parent Clients form. I see that in the script editor, I can tap on one-to-many icon next to Appointments, and get its ID, but after that, I’m at a loss.