Using Grouping with RG


I am trying to find a solution for summing up data from a repeating group.

Expenses are entered - Can have many of the same type

I want to show a list of the type of expenses and their sum per month. Details are showed (in yellow background) only when the Type is clicked.

What I have tried
An Expense repeating group Grouped by Type
Inserted a second Expense repeating group filtered by parent group Type Grouped by Month, But inside this repeating group the only variable I have available is Month, I was expecting to sum this month type.

I tried to do a search inside a text field to get the data again, but I can’t access the first RG Type just the current month.

I have included a few screenshots of IU, database and page

Suggestion would be appreciated.

Thank you


I am not sure how many repeating groups you have there or if any are nested but you should be able to say RepeatingGroup Thing’s List of Thing’s :each items: whatever: sum.