Jul 04, 2023 05:02 PM
When there is a link field that links to records within the same table, is there a way to show the records that are linked FROM (as well as linked TO)? For example, see screenshot below, where there is a list of companies and a link field called "Key Customers" which references the list. I have dummied up the "Key Customer Of" field by creating a new link field - but I actually want this field to generate automatically based on the "Key Customers" field. In other words, instead of only showing the target records, can I also show the source records?
I think the answer is no because Airtable is a relational database and not a graph database. I know also that the documentation states that best practice would be to keep the customers in a separate table, but in this case that would require double-entry of many companies, which I very much want to avoid. If anyone has figured out a clever workaround I'd love to know!
Jul 04, 2023 06:22 PM
Not within the same table, unfortunately. Almost all other database apps offer this functionality natively, so it’s definitely not a silly question at all. It’s actually a necessity in database apps!
Unfortunately, the only way you could do this within Airtable would be to run a script to do it. Here’s a sample script: https://builtonair.com/script/same-table-linked-records-backlinks/
You could also do with an external automation app like Make, but scripting is likely the quickest & easiest way to do this.
Jul 04, 2023 06:58 PM
Separate Relation and Organization tables can solve this problem.
Record links in the same table will not generate bi-directional links.
Add the following fields to the relation table
Organization name(Primary)
Type: Formula
Formula: {Organization}
Organization
Type: Link to another table
Link: Organization table (single)
Customers
Type: Link to other tables
Link: Organization table (multiple)
Key Customer of
Type: Lookup
Linked record field to use for lookup : Organization
Editor field you want to look up : Customers
Jul 04, 2023 08:55 PM - edited Jul 05, 2023 06:14 AM
@Anna wrote:When there is a link field that links to records within the same table, is there a way to show the records that are linked FROM (as well as linked TO)?
Airtable does NOT have native support for backlinks to same-table links. However, you can maintain same-table backlinks using two same-table link fields and automation scripts. I sell scripts to maintain same-table backlinks on my Gumroad store. This package includes both a button script that you can run to set up your initial backlinks, and an automation script for ongoing maintenance of the two linked record fields.
Note that the script that @ScottWorld linked to does not include an automation script for maintaining links, and does not take advantage of features like Script settings because they were released after that script was written. While it is useful for initially setting up a backlink field, it will not maintain it for you automatically.
Jul 05, 2023 02:21 AM
Jul 05, 2023 05:42 AM
p.s. @kuovonne You had a typo in your first few words. You meant to say “Airtable does NOT have native support.”
Jul 05, 2023 06:15 AM
Thanks for the catch. I was typing late last night while also taking care of last minute things for a major trip.
Jul 05, 2023 07:37 AM
Thanks for the responses, @ScottWorld and @kuovonne (and @ScottWorld, I didn't think it was a silly question 😂)! This seems like a major gap in Airtable's functionality and not difficult to add from a technical standpoint - does anybody know if it's on the roadmap?
Jul 05, 2023 07:48 AM - edited Jul 05, 2023 07:49 AM
Airtable doesn’t release its roadmaps, even to its top Airtable consultants like myself.
Sadly, Airtable is also a very customer-hostile company. I have rarely seen them implement any customer feature requests in the last 6 years. Unfortunately, they are by far the worst software company in terms of customer and consultant relations that I have ever dealt with in my entire life.
For a more professional database app that has this functionality natively built into it, you can always turn to FileMaker. Contact me if you need referrals to FileMaker developers, since I no longer do that anymore.
I would say that there is a 99.999% chance that this feature will never make it into Airtable.