Skip to content
PlanetNoCode
0:06:32
194
7
1
Last update : 02/10/2024

Effortlessly Manage Multiple Database Entries in Bubble.io 🛍️

Ever struggled to save multiple items separately in your Bubble.io database? 🤔 This concise breakdown equips you with the knowledge to effortlessly manage multiple entries like a pro!

Why This Matters 🤔

Imagine building a grocery list app. Your users need to input multiple items, each saved individually in your database. This is where the magic of backend workflows comes in! ✨

Unveiling the Power of Backend Workflows ⚙️

While frontend workflows are great for simple tasks, backend workflows are your secret weapon for handling complex operations behind the scenes. Let’s break it down:

1. The Problem: Single Line Input vs. Multiple Database Entries

When a user inputs “Apple, Banana, Orange” in a single line, how do you separate each fruit into individual database entries? 🤔

Solution: Backend Workflows to the Rescue! 🦸

  • Enable backend workflows in your app settings (requires a paid Bubble plan).
  • Think of backend workflows as running separately for EACH item. If you have three comma-separated values, the backend workflow will run three times!

2. Creating Your Backend Workflow: A Step-by-Step Approach 🪜

  1. New Backend Workflow: Create a new backend workflow; let’s call it “SaveShoppingItem.”
  2. Passing Data: Determine the data you’re sending from the frontend to the backend (in this case, it’s simple text).
  3. Database Action: Inside the backend workflow, add an action to create a new “item” in your database.
  4. Dynamic Data: The “label” for each new item will be the individual piece of text sent from the frontend.

3. Harnessing the “Split By” Operator: Your Text-Splitting Ally 💡

  • The “Split by” operator is CRUCIAL. It allows you to take that single line input (“Apple, Banana, Orange”) and transform it into individual text strings.
  • Use a comma as your delimiter in the “Split by” operator.

4. Connecting the Pieces: Frontend to Backend 🤝

  1. Schedule API Workflow on a List: In your frontend workflow, instead of directly creating a database item, choose “Schedule API Workflow on a List.”
  2. Select Your List: The “list” here is your multi-line input’s value.
  3. Splitting the Text: Use the “Split by” operator on your input value, separating by a comma.
  4. Trimming for Cleanliness: Use the “trimmed” operator to remove any unnecessary spaces.
  5. Connect to Backend: Finally, connect this frontend workflow to your “SaveShoppingItem” backend workflow.

The Outcome: Clean, Separate Database Entries 🎉

  • When the user clicks “save,” the frontend workflow springs into action.
  • It splits the input into individual items.
  • The backend workflow then diligently creates a separate database entry for each item.

Resource Toolbox 🧰

Supercharge Your Bubble.io Skills 🚀

This method empowers you to create more dynamic and user-friendly Bubble.io applications. Experiment, build amazing things, and unlock the full potential of no-code!

Other videos of

Play Video
PlanetNoCode
0:06:58
16
0
0
Last update : 13/11/2024
Play Video
PlanetNoCode
0:06:07
19
2
0
Last update : 07/11/2024
Play Video
PlanetNoCode
0:04:48
709
11
0
Last update : 07/11/2024
Play Video
PlanetNoCode
0:03:30
370
18
3
Last update : 30/10/2024
Play Video
PlanetNoCode
0:04:54
757
31
3
Last update : 30/10/2024
Play Video
PlanetNoCode
0:08:11
45
2
0
Last update : 30/10/2024
Play Video
PlanetNoCode
0:03:11
774
20
2
Last update : 09/10/2024
Play Video
PlanetNoCode
0:03:52
254
8
0
Last update : 09/10/2024
Play Video
PlanetNoCode
0:05:57
336
15
0
Last update : 02/10/2024