# Sum a value and by grouping

**URL:** <https://community.glideapps.com/t/sum-a-value-and-by-grouping/68116>\
**Category:** Ask for Help\
**Created:** [November 24, 2023, 4:29pm UTC](https://community.glideapps.com/t/sum-a-value-and-by-grouping/68116 "2023-11-24T16:29:48Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![zephir](https://avatars.discourse-cdn.com/v4/letter/z/e95f7d/32.png) [@zephir](https://community.glideapps.com/u/zephir)\
**Post date:** [November 24, 2023, 4:29pm UTC](https://community.glideapps.com/t/sum-a-value-and-by-grouping/68116/1 "2023-11-24T16:29:48Z")

</div>

Hi,  
To make a certain quantity of the TRI00155 knitwear, I have linked the necessary yarn orders (FIL00227 and FIL00129). I would like to determine the cumulative quantity per type of yarn. Does anyone have any tips on how to do this?

 ![c1](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/a/c/ac28cda9c4f0067e4187762f2a3094b715550925.jpeg)  
 ![c2](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/4/1/418f87e4d367f5337731de437985e6db68a86b5d.jpeg)  
 ![c3](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/8/9/8917b7855fb9015e94ad22f942716b502f94eb4f.jpeg)

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [November 25, 2023, 1:22am UTC](https://community.glideapps.com/t/sum-a-value-and-by-grouping/68116/2 "2023-11-25T01:22:58Z")

</div>

So you want to show the cumulative sum of FIL00227 and FIL00129, providing there can be multiple instances of each in the query?

---

<div class="post-metadata">

**Author:** ![zephir](https://avatars.discourse-cdn.com/v4/letter/z/e95f7d/32.png) [@zephir](https://community.glideapps.com/u/zephir)\
**Post date:** [November 25, 2023, 10:48pm UTC](https://community.glideapps.com/t/sum-a-value-and-by-grouping/68116/3 "2023-11-25T22:48:52Z")

</div>

Yes. To solve this problem, I decided to create a additionnal table that directly links the yarn type (FIL00227 and FIL00129) and the knitwear (TRI00155). I’ll use this table to evaluate cumulative quantity for each yarn.  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/5/0/50da5ed92b5d6a690fc80fb1723d6798a27d7df9.png)  
Thanks.
