# Lookup Latest Row (idea for lookups with Multiple Relations)

**URL:** https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441
**Category:** Feature Requests
**Created:** [July 14, 2020, 12:28am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441 "2020-07-14T00:28:22Z")
**Posts on this page:** 13
**Page:** 1

<div class="post-metadata">

### Author: ![kyleheney](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/kyleheney/32/41173_2.png) [@kyleheney](https://community.glideapps.com/u/kyleheney)
#### Post date: [July 14, 2020, 12:28am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/1 "2020-07-14T00:28:22Z")

</div>

Currently lookups don’t work well (or at all) with Multiple Relations. I have a use case where it would be helpful to pull the last row from a Multiple Relation.

I currently use a query to create a new sheet that filters the latest entries, but doing this through a Multiple Relation lookup would be cleaner… I think.

---

<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: [July 14, 2020, 12:59am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/2 "2020-07-14T00:59:21Z")

</div>

Would an inline list \> show only x component \> sort descending by sheet order work?

---

<div class="post-metadata">

### Author: ![kyleheney](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/kyleheney/32/41173_2.png) [@kyleheney](https://community.glideapps.com/u/kyleheney)
#### Post date: [July 14, 2020, 1:27am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/3 "2020-07-14T01:27:55Z")

</div>

Potentially…

---

<div class="post-metadata">

### Author: ![Nocodemobileapp](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/nocodemobileapp/32/6721_2.png) [@Nocodemobileapp](https://community.glideapps.com/u/Nocodemobileapp)
#### Post date: [July 14, 2020, 4:23am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/4 "2020-07-14T04:23:57Z")

</div>

Are you looking for the last row of your sheets?  
According to my knowledge last roll don’t increase with multiple relations?  
You can use rollup column to count or sum any value in sheets. [https://docs.glideapps.com/all/reference/data-editor/computed-columns/rollup](https://docs.glideapps.com/all/reference/data-editor/computed-columns/rollup)

Feel free to let me know I be any mean of help.

---

<div class="post-metadata">

### Author: ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)
#### Post date: [July 14, 2020, 12:21pm UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/5 "2020-07-14T12:21:51Z")

</div>

This is multiple steps, but you can do a rollup on your relation to get a max date for example, build a template with the rollup date and whatever you used for your previous relation in the sheet containing the relation and The sheet you are relating to. Then create a new single relation using the template to get only the last record. It’s a lot of Glide columns, but it’s better than a completely separate sheet and duplicated data.

---

<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: [July 14, 2020, 12:24pm UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/6 "2020-07-14T12:24:06Z")

</div>

@Jeff suggested this to me several months back and I’ve used this logic a few times now…it works!

---

<div class="post-metadata">

### Author: ![XceL](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/xcel/32/91079_2.png) [@XceL](https://community.glideapps.com/u/XceL)
#### Post date: [March 12, 2022, 3:10am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/7 "2022-03-12T03:10:37Z")

</div>

> [@Jeff\_Hager](#):
>
> This is multiple steps, but you can do a rollup on your relation to get a max date for example, build a template with the rollup date and whatever you used for your previous relation in the sheet containing the relation and The sheet you are relating to. Then create a new single relation using the template to get only the last record.

This is brilliant! Been wondering how to do nested relation/lookups for a while and completely gave up on it 😅  
This is so amazing, thanks @Jeff_Hager

---

<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: [March 12, 2022, 4:55pm UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/8 "2022-03-12T16:55:04Z")

</div>

You can also do a single value \> last \> whole row

---

<div class="post-metadata">

### Author: ![Jonas](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jonas/32/50443_2.png) [@Jonas](https://community.glideapps.com/u/Jonas)
#### Post date: [November 15, 2022, 7:58am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/9 "2022-11-15T07:58:21Z")

</div>

I can’t seem to get this to work. Is the method still functional, and/or have there come any new solutions to the problem?

---

<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: [November 15, 2022, 8:02am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/10 "2022-11-15T08:02:41Z")

</div>

What is your actual goal?

---

<div class="post-metadata">

### Author: ![Jonas](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jonas/32/50443_2.png) [@Jonas](https://community.glideapps.com/u/Jonas)
#### Post date: [November 15, 2022, 8:22am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/11 "2022-11-15T08:22:07Z")

</div>

Thanks for the quick reply @Darren_Murphy 🙏🏼

I have a details screen of a car, where I’m showing a map of where it’s parked. I have an “Add new parking” button, which takes users to a form screen, where they can add a new parking. When they submit this form, a new row is created in a “Parking” table (the car obviously sits in a “Car” table).

Now, on the details screen of the car, I’d like the map to show the latest parking submitted, so users always know where their cars are parked.

Hope that’s context enough 🙂

---

<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: [November 15, 2022, 9:05am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/12 "2022-11-15T09:05:14Z")

</div>

Okay.

So I assume that you have a multiple relation column in your Cars table that links to the Parking table?  
Assuming that’s the case, you should be able to use the method that @Robert_Petitto mentioned:

> [@Robert\_Petitto](#):
>
> You can also do a single value \> last \> whole row

The Single Value → Last → Whole Row would be via your multiple relation.

---

<div class="post-metadata">

### Author: ![Jonas](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jonas/32/50443_2.png) [@Jonas](https://community.glideapps.com/u/Jonas)
#### Post date: [November 16, 2022, 5:59am UTC](https://community.glideapps.com/t/lookup-latest-row-idea-for-lookups-with-multiple-relations/12441/13 "2022-11-16T05:59:24Z")

</div>

Correct. It’s a multiple relation.

@Robert_Petitto’s method worked. I had overlooked the “Whole row” option. Now I’m running look ups on the single column whole row, which updates to the latest row automatically.

Thank you very much for the assistance @Darren_Murphy 👍🏼
