Hi Gaby! Thank you for taking a stab at this problem. :slight_smile:

I left out a lot of specifics to try and focus on the main problem. I actually already have a nested repeating group similar to what you describe. My first attempt was to just show one row of the nested group if the item is not in a group, or to show X rows when there is a group. So I’m thinking along the same lines.

I got tripped up on knowing how many items to pull from the unfiltered list so I end up with the right amount of items. I can’t know how many items to count for each one so that I know when I’ve reached the desired goal without some sort of loop like a traditional function. At least that’s how I keep thinking of it.

I’ll check out your solution soon. For the short term, I decided to simplify my solution to only show a group if it is the first group and it appears in the first 5 items. So if [3, 4] are a group I might end up with only 4 Things:

1: 1
2: 2
3: [3, 4]
4: 5

or with [5, ,6, 7] I might have 5 Things:

1: 1
2: 2
3: 3
4: 4
5: [5, 6, 7]

Both examples only show one group.

This would result because initially I’m only looking at the first five items, but if there is a group, I’ll pull the whole group, so I might have fewer than 5 things (1st example) or 5 things with the extra rows needed (2nd example).

I’ll circle back later and include the full solution. I appreciate the input.

By the way, I finally launched my app! It’s currently in beta and has come a long way since I finished your program. Although it has taken me a long time to get this out, it’s a lot more complete and polished than it would have been had I released it last year. (I know I shouldn’t worry about polish, but I know my market and it will not tolerate substandard apps, even in beta…) Your program was an amazing jump start to the process though and really helped me to progress quickly in many ways. I hope you’ll take a look. I’m quite proud of how it turned out! :wink: