# Multiple cell as look up

**URL:** <https://community.glideapps.com/t/multiple-cell-as-look-up/74457>\
**Category:** Ask for Help\
**Created:** [June 28, 2024, 6:53pm UTC](https://community.glideapps.com/t/multiple-cell-as-look-up/74457 "2024-06-28T18:53:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![wwang](https://avatars.discourse-cdn.com/v4/letter/w/85e7bf/32.png) [@wwang](https://community.glideapps.com/u/wwang)\
**Post date:** [June 28, 2024, 6:53pm UTC](https://community.glideapps.com/t/multiple-cell-as-look-up/74457/1 "2024-06-28T18:53:07Z")

</div>

I have a table (A) with columns `material`, `color`, and `unit price`  
I have another table (B) that has many columns but also include `material` and `color`  
How can I reference A’s `unit price` in B, using it in a math cell to calculate total cost by looking up both `material` and `color` from B in A.

---

<div class="post-metadata">

**Author:** ![Robert\_Petitto](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/robert_petitto/32/25193_2.png) [@Robert\_Petitto](https://community.glideapps.com/u/Robert_Petitto)\
**Post date:** [June 28, 2024, 10:07pm UTC](https://community.glideapps.com/t/multiple-cell-as-look-up/74457/2 "2024-06-28T22:07:22Z")

</div>

Create a relation in table B between material and material. Add a query column that references the relation and uses color as a filter (you could simply just create a query column of the entire table and filter by both material and color color, but we’ve been told this is slower than starting off with a relation). Use a single value column, referencing the query to look up the unit price.

---

<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:** [July 5, 2024, 10:07pm UTC](https://community.glideapps.com/t/multiple-cell-as-look-up/74457/3 "2024-07-05T22:07:31Z")

</div>

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