Multiple varying INSERT command

Hey folks,
I want to INSERT multiple records with one action (button tap).

My use case is - A user has many profiles. Each profile can have many tasks assigned.

I want to add a task to a profile. But if the user chooses (via radio button) to add that particular task to all profiles related to their account, they should be able to. But this requires firing off multiple INSERT actions.

I am not sure how to perform a variable number of INSERT actions for a button push. Any help is much appreciated.

I think “bulk” modif are not implemented (yet) in Adalo, i.e. you cant delete various records at once…so within Adalo, this is not possible…>> you’d need external tools

@vjragavan Hi Vijay, can you model it in a collection like:
profile has tasks,
user has profiles, etc.

Or is it to diverse?

It is modeled like that only. I’m not sure how to get other profiles associated with the current user. Even if I get the list of users, how can I call n number of INSERTs?

If you can model it in collections, can you do an CSV upload after filling it in Excel? Could be a manual one time or automated with Zapier etc.

TBH, that went over the head for me. If you don’t mind, can you explain it to me? :slight_smile:

I was just brainstorming for workarounds to simulate mass inserts, which could be done by uploading CSV to the database tables.
But actually I don’t have enough information to understand the data model behind it.
You wrote:

I don’t understand the background, why you need to update all profiles when a user selects a task to be added.

Let’s say, I am creating an activity tracker for a family.

When I want to add “drink 2L of water” to one profile, I want to be able to add it to all family members.

I own the account, but each family member will have their profiles, and each profile can have their own activities and few common ones too. Hope this use case is making it clear.

hmm, I still think this is not possible in Adalo - as of now…

in other DB like SQL you could write stuff like,
Select all users in Table family and add 2 to field water
… and Bam, in a second this would update 10.000 records at once…!
This is a CPU/RAM Server intensive op. more if you have 1 million records.

In Adalo, this “feature” does not exist., you would have to manually clic (i.e. with a button on a form) on each line of records to add 2 litters to their field “water”…

  • to add, substract or divide.

(*someone correct me if i 'm wrong about this event)

…or use some third party App of Adalo to do that for you.
Its just a Way to preserve/minimize DB CPU resources…for now

Yeah, that’s exactly what I’m not sure of. Even if my collection is from Airtable, I don’t know if we can perform something like this even with the help of Adalo + Zapier or Integromat.

i don t use those tools (yet!!)
there are others here that do and probably can answer

…as for updating in bulk, check this video, that s what Sean Tierney could do with a tool called Katalon…not free :cold_face:
Bulk records modifications with Katalon

The use case you suggested (bulk delete) is different. Thank you though.

True, and deleting is most always much more simple than doing insert or modify… but if you find a free “way” to do that you can share here. :v:

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