# Unique values to be added to new table

**URL:** <https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978>\
**Category:** Ask for Help\
**Created:** [February 11, 2025, 6:34am UTC](https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978 "2025-02-11T06:34:10Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lachlan](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/lachlan/32/79092_2.png) [@Lachlan](https://community.glideapps.com/u/Lachlan)\
**Post date:** [February 11, 2025, 6:34am UTC](https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978/1 "2025-02-11T06:34:10Z")

</div>

Appreciate any support anyone can provide…

i have one table (Inventory Purchases) that is populated by the user. I want some of these fields to be summarised in a different table (Inventory Database). If done in Excel, it would look like a pivot table (any purchases of the same type are summed together, rather than being treated as a new item).

ie, in the below the highlighted rows i want to show as one row Qty = 9, Cost = $150 within the Inventory Database table

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/0/8/0844f11e35692020f244675d6850cfe916f62e6e.png)

This feels like there should be an easy fix, but i can not figure out how to get there!

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [February 11, 2025, 7:57am UTC](https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978/2 "2025-02-11T07:57:11Z")

</div>

You can use the technique described below:

> [@Grouping and Summarizing Unique Values In a Table](https://community.glideapps.com/t/grouping-and-summarizing-unique-values-in-a-table/79874/2):
>
> Create a multiple relation column that matches the Publisher with itself. Create a rollup column, target it at the multiple relation column, and select Sum-\>Impressions (or sum-\>Media Costs) To create something you can use as a filter: Use a single value column to take the first RowID from the multiple relation Create an if-then-else column and apply the following condition: – If RowID is single value RowID, then true Use the if-then-else column as a collection filter (only show rows where …

---

<div class="post-metadata">

**Author:** ![Lachlan](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/lachlan/32/79092_2.png) [@Lachlan](https://community.glideapps.com/u/Lachlan)\
**Post date:** [February 12, 2025, 12:25am UTC](https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978/3 "2025-02-12T00:25:23Z")

</div>

Thanks Darren. Can see theres quite a few threads on this issue (once i knew the terminology to use!). Everything ive found so far though provides solutions to keep the sum/rollup within the same table. Do you know of a solution that will summarise this info into a NEW table?

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [February 12, 2025, 12:52am UTC](https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978/4 "2025-02-12T00:52:06Z")

</div>

Yes.

- Create a table and index the rows using the second method described [here](https://community.glideapps.com/t/how-do-i-create-an-auto-incrementing-row-number-with-glide-tables/39572).
- Add enough rows to cover the total number of unique categories
- Create a lookup column that targets the Category column in your transactional table. This will give you an array of Categories.
- Use a Unique Elements column to remove duplicates from the array
- Use a Single Value column, taking the Nth from start of the previous column, where N is the Row Index number. This should give you a list of Categories, one in each row.
- Create a multiple relation column, matching each Category with the same column in your transactional table
- Create whatever rollups you need via that relation.

---

<div class="post-metadata">

**Author:** ![Lachlan](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/lachlan/32/79092_2.png) [@Lachlan](https://community.glideapps.com/u/Lachlan)\
**Post date:** [February 12, 2025, 2:39am UTC](https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978/5 "2025-02-12T02:39:49Z")

</div>

you are a dead set genius Darren. Thankyou!!

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/system/32/53398_2.png) [@system](https://community.glideapps.com/u/system)\
**Post date:** [February 19, 2025, 2:40am UTC](https://community.glideapps.com/t/unique-values-to-be-added-to-new-table/79978/6 "2025-02-19T02:40:04Z")

</div>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
