# RG - get the total value from a SUM

**URL:** <https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481>\
**Category:** App Organization\
**Created:** [October 16, 2024, 12:13pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481 "2024-10-16T12:13:42Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Acatenango](https://avatars.discourse-cdn.com/v4/letter/a/a8b319/32.png) [@Acatenango](https://forum.bubble.io/u/Acatenango)\
**Post date:** [October 16, 2024, 12:13pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/1 "2024-10-16T12:13:42Z")

</div>

Hi Everyone,

In a RG, I have lines into categories, and I get the sum for each category with :sum

I’m trying to calculate the grand total of all of this sums, is that possible?

In the example below, how to get the total of 500 + 300 + 1800 which are obtained with the function :sum?

![image](https://us1.discourse-cdn.com/bubble/original/3X/4/8/4881105cec56eae69a54c417a95316a5d6dbdfa7.png)

Thanks for your help 🙏

---

<div class="post-metadata">

**Author:** ![cyril.legaspi](https://avatars.discourse-cdn.com/v4/letter/c/d07c76/32.png) [@cyril.legaspi](https://forum.bubble.io/u/cyril.legaspi)\
**Post date:** [October 16, 2024, 12:50pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/2 "2024-10-16T12:50:45Z")

</div>

Can you share the structure of your Data Types?

---

<div class="post-metadata">

**Author:** ![Acatenango](https://avatars.discourse-cdn.com/v4/letter/a/a8b319/32.png) [@Acatenango](https://forum.bubble.io/u/Acatenango)\
**Post date:** [October 16, 2024, 1:11pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/3 "2024-10-16T13:11:08Z")

</div>

Sure I have created 3 DB: Catogy, Equipment, Trip  
Each trip can have multiple categories, and each category can have multiple equipments

 ![image](https://us1.discourse-cdn.com/bubble/original/3X/8/a/8afeebcf183f0ab225a8a5fa5e1e04b770764f9b.png)

---

<div class="post-metadata">

**Author:** ![cyril.legaspi](https://avatars.discourse-cdn.com/v4/letter/c/d07c76/32.png) [@cyril.legaspi](https://forum.bubble.io/u/cyril.legaspi)\
**Post date:** [October 16, 2024, 1:33pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/4 "2024-10-16T13:33:30Z")

</div>

How about the Trip Data Type?

---

<div class="post-metadata">

**Author:** ![Acatenango](https://avatars.discourse-cdn.com/v4/letter/a/a8b319/32.png) [@Acatenango](https://forum.bubble.io/u/Acatenango)\
**Post date:** [October 16, 2024, 1:38pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/5 "2024-10-16T13:38:58Z")

</div>

Here is the Trip Data type:

 ![image](https://us1.discourse-cdn.com/bubble/original/3X/2/e/2e72cd9181ac2a66ea6108c7f66f8471de2f0528.png)

---

<div class="post-metadata">

**Author:** ![cyril.legaspi](https://avatars.discourse-cdn.com/v4/letter/c/d07c76/32.png) [@cyril.legaspi](https://forum.bubble.io/u/cyril.legaspi)\
**Post date:** [October 16, 2024, 2:11pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/6 "2024-10-16T14:11:54Z")

</div>

Is this how you structure your Equipment Data Type?  
 ![equipment](https://us1.discourse-cdn.com/bubble/original/3X/b/c/bca16875b559de2429313bc1bc15d53344ea4ef9.png)

---

<div class="post-metadata">

**Author:** ![Acatenango](https://avatars.discourse-cdn.com/v4/letter/a/a8b319/32.png) [@Acatenango](https://forum.bubble.io/u/Acatenango)\
**Post date:** [October 16, 2024, 2:38pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/7 "2024-10-16T14:38:20Z")

</div>

Almost, few more fields but they are not really important for this task

 ![image](https://us1.discourse-cdn.com/bubble/original/3X/0/b/0b240b4c35fc3a2691783a3fff6466efb0555cfa.png)

---

<div class="post-metadata">

**Author:** ![cyril.legaspi](https://avatars.discourse-cdn.com/v4/letter/c/d07c76/32.png) [@cyril.legaspi](https://forum.bubble.io/u/cyril.legaspi)\
**Post date:** [October 16, 2024, 3:03pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/8 "2024-10-16T15:03:23Z")

</div>

Can you try this?  
 ![trip](https://us1.discourse-cdn.com/bubble/original/3X/c/8/c806040d839ceda3f54ed6c76e2b7fe1480f6c99.png)

---

<div class="post-metadata">

**Author:** ![Acatenango](https://avatars.discourse-cdn.com/v4/letter/a/a8b319/32.png) [@Acatenango](https://forum.bubble.io/u/Acatenango)\
**Post date:** [October 16, 2024, 3:29pm UTC](https://forum.bubble.io/t/rg-get-the-total-value-from-a-sum/344481/9 "2024-10-16T15:29:34Z")

</div>

This is working perfectly you nailed it!  
Thanks so much @cyril.legaspi you made my day
