Nested Repeating Group Table Cell Reference

Having an issue when making a table of values out of nested repeating groups. Repeating Group 1 generates rows based on a list of Data Type A, Repeating Group 2 is inside Repeating Group 1’s cell, and generated columns based on Data Type B. The problem I’m having is I can’t seem to figure out how to refer to Repeating Group 1 from within a cell in Repeating Group 2. Example, display Thing B data and Thing A data with reference to both Repeating Group 1 and Repeating Group 2’s indexes. Hope that makes sense, this is driving me crazy.

I had a table working but the rows were static / not repeating groups and the columns were dynamic / repeating groups, but I am trying to redesign the table and data structure following the DRY principle, but now I’m not so sure I can even achieve this, and if I can I am at a loss for how to do so. It’s not essential that the rows are generated through repeating groups, however, if they aren’t it means I’m going to have to repeat myself 15 times, within workflows and design, which seems to violate DRY so I want to get this right before going to far with development on this project.

wondering why I’m not getting any replies here, I feel like it’s a pretty straightforward issue. Please let me know if I need to include pictures or reword things at all or any additional information that is required. Really need to solve this before moving on and I need some guidance

I’m not sure I’m following what you’re trying to do :laughing:

Bubble is weird with referencing inside repeating groups but you can reference Repeating group 1's item# [current cell's index] if that helps at all. Is there a database relation between these two data types? Or are you just trying to match up things with indexes?

If you can screenshot a visual of what you are trying to do

1 Like

Hey tylerboodman!

I’m trying to make a table using two repeating groups. The parent repeating group (Repeating Group 1) will create the rows based on a data type (Data Type A) returned from a search. Inside Repeating Group 1, there is a child repeating group (Repeating Group 2) that creates columns based on another data type (Data Type B) .

I’m trying to access fields of both data types from within Repeating Group 2 which requires using the index of both RG 1 and 2, the column number and row number essentially, but I am only able to refer to RG 2’s index number (column number) from within the cell.

I’m kind of trying to recreate what you are describing… What’s the database relationship between these two types? Does your Type B contain a reference to the Type A?

This has edit access if you want to make it closer to what you are trying to do.
What I have so far is a Search for Type A, then inside it searches for Type B with a constraint that the B’s Type A = Current cell’s Type A

The text inside is referencing the Type A Row by looking at it’s B’s Type A

Also by putting the Repeating group for Type B in a group, you can reference that group’s Type A from inside the cell of Type B


Thank you so much for recreating this page in your test project. I adjusted some thing with regards to how the data types relate to each other, and created some objects of those types to illustrate the problem. In the design tab, the text contained in repeating group c needs to refer to repeating group b’s cell’s index:

The best way I could represent what data I’m to display in typical code syntax would be, assuming the repeating groups are the result of some kind of recursion like a for loop:


(list of Type B objects stored on Type A object)

However there is no way to refer to both index ‘i’ and ‘j’ inside of the inner ‘j’ loop aka Repeating Group C

So check it now, in the elements tree you can see a “Group index” and I set it to number, then that references the cell’s index. So now you can reference that group’s number (the index). Weird workaround but hopefully that’s what you needed.

This does seem a little strange though… for example the main repeating group searches for Parent Type A, with a constraint Name = A1. But every row is going to have that same constraint so I think you will only get one row?

1 Like

There are 3 Type B objects where Parent A == A1, so there should be 3 Rows. Ok, so this work around is interesting, definitely works but I’m wondering if there is a better way of structuring the database / relating the types in the first place.

edit: I can share a class diagram if that would help but I realize that it may be outside the original scope of this post.

Yea I think Bubble loses context of the cell’s index because it’s buried in another cell but the workaround is fine to use.

And yea I think this can structured differently… I don’t think I see anyone uses indexes to cross reference things, instead you just store the relationship in the database and use search constraints to form that relationship on screen (if that makes sense)

1 Like

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