Parent/Child Relationship

Hi All,

I am creating a logging system which will be used within an Event Control Room.

The system will log all calls and radio messages inbound and outbound. That being said, by the nature of what this function does, a user should not be able to edit a call once it has been logged, only add updates.

I have 2 tables:

  1. Call details this records all of the information from the initial call
  2. Call updates this records updates for the call

I need a way to link the two tables together so that the updates for Call 1 only show for Call 1 and the updates for Call 2 only show for Call 2 etc etc.

Is there a way to achieve this?

TIA!


As long as you have a common value in both tables, such as a Call ID, you can create a relation in the Call table linking it to the Updates table.

With that relation, you can have a collection of Updates in the Call Detail Screen sourced from the relation.

3 Likes

Sounds like this is exactly what I need! I’m looking at making a sequential counter for Call Reference. This would be the field in each table.

Could you advise on a simple sequential counter?

For the sequential counter, take a look at the video in the below doc:

2 Likes

Thanks, do I have to do this through a third party? Is there not a way I can do this within Glide?

It depends. Glide does not do atomic operations, so if it is essential that you should never have duplicates, then you should use the solution shown in the video.

Otherwise, see below:

1 Like

Sorry to reply again, @Jeff_Hager. Is it possible you can better explain your solution here?

Here is the documentation on creating a relation between two tables.

https://www.glideapps.com/docs/automation/computed-columns/relations

Here is documentation on Collections. The source of a collection can be set to the relation on the Call Details screen.

Review the documentation and let us know if you are still not understanding something.

2 Likes

Thanks, Jeff.

The thing I’m not understanding…

I am using ‘ROW ID’ as the unique reference for each new ‘Call’ being logged. This is in the ‘General Call’ data sheet.

I can’t work out how the call ID is copied across to the ‘Call Updates’ data sheet to ensure that only updates that are added from that calls page are shown.

I hope this makes sense?

When you use your Add Updates form to add call updates, you can add various Value components to the same form to pass various values from the current parent Call Detail row into the newly added Call Update row. Choose the appropriate Value component to add to your form and set it to write the Call ID into a column in your Call Updates table. That’s the column that your relation will use.