Saving data out of a repeating group

Hi folks :slight_smile:

I finally was able to get my response from Open AI to return me a list of things that I save in a repeating group. Each RG cell contains a “Title” “URL” and “address” field. This is great! But now I’m trying to be able to save each of these to their corresponding field in the database and am having terrible luck doing so. To be crystal clear form the image below, I want to save the results I have on the right into the DB where “The Louvre” is one “Recommendation” (data type) and the fields within that data type are name, URL, address.

I’ve seen on the forum that “Orchestra” plugin was recommended but I couldn’t find clear enough instructions for my level of understanding. If this is still the way to do it could someone please provide step by step info as to how they’ve used Orchestra?

Many thanks!

Since you can show this list in a repeating group, you can also send it to a backend workflow to be processed.

In this backend workflow, you will create a Recommendation with the first, second, and third element of the list. Then, you remove the first three elements and then, you will call the same backend workflow recursively.

This backend workflow will also have a condition to work only if the input list is not empty, so it can stop.

I have created a sample for you. See the demo below. In the demo, the left RG is just a list of text (like your REX repeating group) and the one on the right is the Recommendation data type (Which initially empty).
chrome_y66kMToXjs

When button is clicked it calls a backend workflow:

And the backend workflow accepts a list of text:

And created the recommendation with the first two items (in your case, it will be 3):
image

Then, call the workflow again, this time removing the first two items:

You can check the whole example here: Tests for Forum 8 | Bubble Editor (the example will stay online, but of course, I have to cancel the trial starter plan that makes the backend workflows available).

@hergin Thank you so so so much for spending time answering me, I really appreciate it! Your instructions are very clear to follow. My only problem now is that my repeating group is not a list of texts but is formatted to receive the json response from ChatGPT.


Because of this then in my workflow when I try to send the “RepeatingGroup text’a list of texts” it will not work for me because it is looking at a more specific data type.
Screen Shot 2024-03-27 at 11.17.20 AM
My only option then becomes :raw body text but when I send that in the workflow my data entry is empty.

Any suggestions how I could get around this?

I don’t know unfortunately. You have to convert the items or get the items in the repeating group somehow. How does your repeating group’s cell view the data? How does Louvre Museum get printed for example?

On the left-hand side, a user can enter text (recommendations they’ve received from a friend). Then I send a call to chatgpt and when I get the response I run a backend workflow to convert the response into a json format that I want that will fit my data type of REX (recommendation). That Rex has a title, url, and address. Therefore the repeating group is formatted to receive that json response.

Oh I thought it is 3 different texts each in a cell. So there is 3 texts in a cell. Can you show how one of them is printed in a cell? How does Louvre Museum get printed for example in the editor?

Now, they are specific extractions.
I included a link to a Loom because I think it may be helpful to see everything:

I guess raw body might still be returning a valid json for just one entry of Rez (with title, url and address). Maybe in your backend workflow, you couldn’t parse the json to put the corresponding fields of json to the corresponding fields of Recommendation in your system. Maybe try printing the each item’s raw body text to a text field in your page first to see what is passing to the backend workflow.

But then there is no way to get the right data into a specific cell, right? For example if I have

Recommendation 1: Name
Recommendation 1: Address
Recommendation 1: URL

but then I don’t get a URL for recommendation 2. Then recommendation 3 information will appear under it like this…

Recommendation 2: Name
Recommendation 2: Address
Recommendation 3: Name

Recommendation 3: Address
Recommendation 3: URL

If all 3 fields are coming together with json, you shouldn’t have this problem. I wonder how the raw looks like.

Hmm I changed it to raw text and the same fields appeared.


If you’re open to zooming let me know and I can DM a calendar invite. I can’t thank you enough for giving this your attention!

Hello I have the same problem as you. I need to display in a list or in a repeating group the answer of Mistral ia. How did you do it? I read your post about the entries but you didn’t give the solution you said you found on this post. Can you share the solution?

Entries into RG is here:

still working on saving :wink:

Thank you very much. That helps a lot!