Help

Re: Viewing only the latest record

3120 0
cancel
Showing results for 
Search instead for 
Did you mean: 
Doug_Gregan
6 - Interface Innovator
6 - Interface Innovator

Hello!

I would like to create a Grid view that only displays the latest record. I’ve played around with formulas, but am not finding success. I’m sure it’s something simple and stupid. I don’t want to have to interact with the Table to get it to update.

I have a Field for the Creation Date and I also have an auto-number ID that I could compare against. Again, I just couldn’t get the logic right.

Thank you, in advance, for your help.

5 Replies 5
AlliAlosa
10 - Mercury
10 - Mercury

You can accomplish this by linking every record in the table to a single record in a separate table (you can also set up an automation to make sure that every record stays linked appropriately).

Once you have the above in place, add a rollup field to the new table (which should only contain one record), and point it at the auto number field on your first table. Use the aggregate function…

MAX(values)

This should give you the highest number of the auto numbered field from table 1 (corresponding with the most recently created record).

Finally, on Table 1, add a rollup field and point it at the field you just created on the new table. Use the below as the formula…

IF(MAX(values) = {AutonumberField}, "Most Recent")

This should give you a field that you can base filters on (i.e where that field is not empty). I hope that helps!

(Welcome back Neads_Admin!!)

I have used the method described by Neads_Admin and it works well to show the latest record in a set of linked records.

However, I am moving away from this method when looking for the latest record in an entire table. Having an entire table with a single record linked to all the records in a different table is a lot of overhead just to identify the single latest record. Plus, it requires an automation to ensure that all new records are linked. Instead, I have a scripting automation that ensures that a checkbox is selected for only the latest record. This eliminates the need for the secondary table and record, and reduces the effort to recalculate rollups, which can impact base speed in very large bases.

Thank you very much for your solution. I will attempt to walk through the steps you’ve outlined and see how it goes. I very much appreciate your time.

Your solution is definitely more streamlined and I would like to attempt it. I assume this is something you coded yourself? Is there a base script that you know of that I could modify?

Thank you very much for making time to answer. I sincerely appreciate it.

Yes, this is a script that I wrote myself. I decided to make the script available for purchase here. You can see a video demo here. You do not need to know how to code or make any edits to the code to use it with your base.

I prefer this script to others I have seen because (1) it can be adapted to any base without editing the code, (2) it does not submit a bunch of extra requests for records with checkboxes that do not need changing, and (3) it throws an error if the field selected is not actually a checkbox field (instead of silently failing).