Hi, I am looking for help regarding adding multiple rows on submission of One Form.
In forms, I have a multi-select choice option, wherein if submitted, creates multiple rows based on how many option submitted
E.g. Name of Product: Product A and in State choice: I select, State A and State B, then it should add Two rows with
are you using a native form or a custom form? (this would be quite easy with a custom form, but could be a little tricky with a native form)
what is the maximum number or rows that might need to be added?
If there are only a handful of permutations, then probably the simplest approach would be a custom action with a number of conditional branches, each adding a different number of rows. However, that wouldn’t scale very well. So if there is a large or indeterminable number of permutations then a better approach is using webhook → Make → Glide API.
Your choice component will write a comma separated list of values to a user specific column. You can use a split text column to create an array from that, and then use a rollup on the array to count the number of items. This will tell you how many rows need to be added. So then in your custom action, you would have something like:
You can see how that can get quite cumbersome and difficult to maintain as the number of rows to be added increases. That’s where Make → API can be a better option. You would send a webhook to Make with whatever data is required, and then use Make to add the appropriate number of rows via the API.
Thank you for this. Great approach.
However, my question on this, how will I add that specific “State” to each of this new Row? I mean, the values will comma separated or the array, how will I specify that, in that particular add row, first selection should be added and next row, second selection should be added?