# Can’t retrieve correct coefficient from Klase/Suga table with Relation + Lookup

**URL:** <https://community.glideapps.com/t/can-t-retrieve-correct-coefficient-from-klase-suga-table-with-relation-lookup/84719>\
**Category:** Ask for Help\
**Created:** [October 3, 2025, 8:56am UTC](https://community.glideapps.com/t/can-t-retrieve-correct-coefficient-from-klase-suga-table-with-relation-lookup/84719 "2025-10-03T08:56:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kristaps\_Lagzdins](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/kristaps_lagzdins/32/92158_2.png) [@Kristaps\_Lagzdins](https://community.glideapps.com/u/Kristaps_Lagzdins)\
**Post date:** [October 3, 2025, 8:56am UTC](https://community.glideapps.com/t/can-t-retrieve-correct-coefficient-from-klase-suga-table-with-relation-lookup/84719/1 "2025-10-03T08:56:10Z")

</div>

**Description:**  
I have two tables:

1. **Koki (Logs)**

- _Suga (no Konteinera)_ → lookup from **Konteineri**
- _Garums (mm)_ → lookup from **Konteineri**
- I need to fetch the correct coefficient from the **Klase/Suga** table based on both species and length.

1. **Klase/Suga (Species/Classes)**

- Column **Suga** (e.g., A Priede, B Egle)
- Column **Garums (mm)** (e.g., 2700, 2900, 4000…)
- Column **Koef** (the coefficient value I want to retrieve into Koki)

**What I’m trying to do:**

- In the Koki table, I created a Template column **Species-Length Key** , expected to look like “A Priede - 4000”.
- In the Klase/Suga table, I created an identical Template column with the same format.
- Then I made a Relation: **Koki → Species-Length Key** to **Klase/Suga → Species-Length Key**.
- Then I added a Lookup to pull the **Koef** from Klase/Suga.

**The problem:**

- Glide shows me all the rows from Klase/Suga instead of just the matching one (e.g., “A Priede - 4000”).
- Sometimes in the Template replacements, my column _“Suga (no Konteinera)”_ doesn’t even appear in the dropdown, only an empty option.
- As a result, the Lookup doesn’t return a single coefficient, but instead a list of all values.

**Question:**  
What am I doing wrong? How can I make the Relation + Lookup return only the single correct coefficient for a given species and length (e.g., A Priede + 4000 → 1.80)?

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/7/8/783d0d6811f0268a53b9f935a12c203b0ab8d9ce.png)  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/6/a/6a4dce7124e3d6e67394f371c2d7542810fa1921.png)  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/f/d/fd33b3fce75166af6eea50467acbbd9798ccd042.jpeg)

---

<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:** [October 3, 2025, 9:19am UTC](https://community.glideapps.com/t/can-t-retrieve-correct-coefficient-from-klase-suga-table-with-relation-lookup/84719/2 "2025-10-03T09:19:41Z")

</div>

- If your Lookup is returning an array of values, that most likely means that your relation is a multiple relation instead of a single relation.
- Also, the template should not be necessary. If you use a Query column instead of a relation, you can apply filtering directly in the column configuration. It would be something like:  
– Species is This row-\>Species  
– Length is This row-\>Length
- If you switch to a Query column, then instead of a Lookup to fetch the coefficent value, use Single Value-\>First

---

<div class="post-metadata">

**Author:** ![Kristaps\_Lagzdins](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/kristaps_lagzdins/32/92158_2.png) [@Kristaps\_Lagzdins](https://community.glideapps.com/u/Kristaps_Lagzdins)\
**Post date:** [October 3, 2025, 10:53am UTC](https://community.glideapps.com/t/can-t-retrieve-correct-coefficient-from-klase-suga-table-with-relation-lookup/84719/3 "2025-10-03T10:53:27Z")

</div>

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/d/c/dc59b78b4e9aa6f092f4db90ea52217fb80ab719.png)  
– Species is This row-\>Species ( It doesnt appear such choice )

---

<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:** [October 3, 2025, 11:29am UTC](https://community.glideapps.com/t/can-t-retrieve-correct-coefficient-from-klase-suga-table-with-relation-lookup/84719/4 "2025-10-03T11:29:08Z")

</div>

Is Species a lookup column from another table?  
Just looking at your earlier screenshots, it appears it might be a lookup via a multiple relation, so it’s returning an array:

 ![CleanShot 2025-10-03 at 19.27.53@2x](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/9/6/96d7ebfcb1e0f905155f1eb3b3c47d10b9978f05.jpeg)

If you make the relation a single relation, then the lookup will correctly return a single text value as opposed to an array, and then it should appear as a filter option with the query.

---

<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:** [October 10, 2025, 11:29am UTC](https://community.glideapps.com/t/can-t-retrieve-correct-coefficient-from-klase-suga-table-with-relation-lookup/84719/5 "2025-10-10T11:29:53Z")

</div>

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