How would I add up all the balances and display that in the app?

Ok so I have a sheet where the users have an associated company id and balance - after looking at this pic how would I get the sum balance for the company id 3 and display it in the app? Is that possible?

Have you tried rollup?

3 Likes

Assuming that you have another sheet that lists all of your companies, and that sheet also includes a company ID column:

  • Create a multi-relation from your Companies sheet, linking to this one and joining by Company ID
  • Then create a rollup through that relation, taking the sum of the “Cliki Balance” column.

That will give you a sum for each company.

4 Likes

Indeed you are a mind reader :slight_smile: there is another sheet with all the comp id’s listed does it matter if this is glide pages and not an app or is it all the same?

Don’t really understand your question. Google Sheets will appear as tables in the Glide Data Editor, and this is where you create these columns. Does that answer the question?

oh, wait - you mean is there a difference in behaviour between a Glide App and Glide Pages? No, there isn’t. It’s the same for both in this case.

1 Like

I was able to actually accomplish this via a pivot table in google sheets pretty quickly - thx for your help :slight_smile:

I think pivot tables do work for your case, but they will consume more rows. For my part, I always try to do as much as I can in Glide. Pivot tables mean more computing done in the Sheets as opposed to Glide, and it will decrease your app’s performance. Unless you have to see it in the Sheets, move things to Glide.

1 Like