# How to permanently link two records in different tables?

**URL:** <https://community.glideapps.com/t/how-to-permanently-link-two-records-in-different-tables/58586>\
**Category:** Ask for Help\
**Created:** [February 28, 2023, 2:12pm UTC](https://community.glideapps.com/t/how-to-permanently-link-two-records-in-different-tables/58586 "2023-02-28T14:12:38Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Josef\_P](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/josef_p/32/55054_2.png) [@Josef\_P](https://community.glideapps.com/u/Josef_P)\
**Post date:** [February 28, 2023, 2:12pm UTC](https://community.glideapps.com/t/how-to-permanently-link-two-records-in-different-tables/58586/1 "2023-02-28T14:12:38Z")

</div>

I have a table USER, COMPANY and OFFER.  
If I create a record in the OFFER table, the company name from the COMPANY table is written to it. If I change the company name in the COMPANY table, the record from the OFFER table is detached. That is, there will be no relationship because the name has changed.  
How to solve this situation?

---

<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:** [February 28, 2023, 2:14pm UTC](https://community.glideapps.com/t/how-to-permanently-link-two-records-in-different-tables/58586/2 "2023-02-28T14:14:21Z")

</div>

Add a RowID column to your Company table, and use that as a CompanyID.  
Then instead of adding the Company name to your Offers table, add the CompanyID, and use that to make the relation. If you subsequently need the Company Name in your Offers table, you can use a lookup through the relation.

---

<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:** [March 1, 2023, 2:14pm UTC](https://community.glideapps.com/t/how-to-permanently-link-two-records-in-different-tables/58586/3 "2023-03-01T14:14:35Z")

</div>

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