How to run a task on list of list

I have a list of users and each user has a list of type Fruit.

I need to create a separate type Basket which contains { User, the type Fruit, a number indicating the number of fruit}

So lets say User Bob has fruits {Plum, Pear}. I need to create new things of type Basket

{ {Bob, Plum, 5}, {Bob, Pear, 3} }

And I need to do this for all users.

I am working through loops with backend flows and iterations but is there a simpler way?

BTW: The example of fruits and baskets is not it. Its different and appropriate to our scenario.

Thanks

This should work:
FIRST go to ‘backend workflows’ and create an API workflow that accepts a value of the type ‘User’.
This workflow creates a new thing of type ‘Basket’ using the information in the ‘User’ value provided to it. Finally use ‘return data from API’ to return the resulting ‘Basket’ thing that this backend api workflow just created.
Now every time you call this backend API workflow from your regular workflow, it will create and return a new ‘Basket’.

THEN try this in your workflow:
Add an action called ‘Schedule API workflow on a list of things’, provide the list of users you need to generate 'Basket’s from, select the API workflow that you just created above and it will do the needful.

Here’s a link that will help:
Scheduled Workflows - Bubble Docs.

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.