Help

Re: Stuck trying to figure how to link tables

Solved
Jump to Solution
1007 0
cancel
Showing results for 
Search instead for 
Did you mean: 
SynopsisLabs
5 - Automation Enthusiast
5 - Automation Enthusiast

Hi,

I am a Airtable newbie and am having a bit of a challenge figuring out how to properly link 2 tables.  

Table 1 (Vehicles) stores Vehicle data - Plate, Make, Model, etc.

2024-03-31 21 51 24.png

 

Table 2 (Fuel Log) stores  - Plate, Litres and Fillup Date

2024-03-31 21 51 44.png

I would like to include a field in Table 1 that shows the total litres for each vehicle.  I have tried linking by Plate (not sure if that is correct) and can't figure out how to show the total litres in table 1. I would also want to be automatically update the total in the Vehicles tables when a new row is added in the Fuel Log table.

Would appreciate any assistance.

Thanks

Steve

2 Solutions

Accepted Solutions
TheTimeSavingCo
18 - Pluto
18 - Pluto

After you create the link between the fields, you can use a rollup with SUM() to get the total litres:
Screenshot 2024-04-01 at 11.20.18 AM.png

Screenshot 2024-04-01 at 11.20.08 AM.png

Link to base

--

re: I would also want to be automatically update the total in the Vehicles tables when a new row is added in the Fuel Log table.

You can handle this by using an automation to paste the value from the "Plate" field into the linked field to the "Vehicles" table.  How to trigger the automation will depend on how you're submitting data into "Fuel Log" though.  If it's via a form, then you can use the trigger "When record created". 

If you're keying stuff in via the Grid view / List view etc, you're going to need to create a checkbox field and trigger your automation off that.  At that point you may as well just manually copy and paste the value from "Plate" into the linked field though

See Solution in Thread

dilipborad
9 - Sun
9 - Sun

Hello @SynopsisLabs ,

The way @TheTimeSavingCo is designed is perfect.

But only a couple of improvements you can make. 

The first field(Primary field) of the Fuel Logs table can be used using Summary(formula), date(created) or AutoNumber.

See Solution in Thread

2 Replies 2
TheTimeSavingCo
18 - Pluto
18 - Pluto

After you create the link between the fields, you can use a rollup with SUM() to get the total litres:
Screenshot 2024-04-01 at 11.20.18 AM.png

Screenshot 2024-04-01 at 11.20.08 AM.png

Link to base

--

re: I would also want to be automatically update the total in the Vehicles tables when a new row is added in the Fuel Log table.

You can handle this by using an automation to paste the value from the "Plate" field into the linked field to the "Vehicles" table.  How to trigger the automation will depend on how you're submitting data into "Fuel Log" though.  If it's via a form, then you can use the trigger "When record created". 

If you're keying stuff in via the Grid view / List view etc, you're going to need to create a checkbox field and trigger your automation off that.  At that point you may as well just manually copy and paste the value from "Plate" into the linked field though

dilipborad
9 - Sun
9 - Sun

Hello @SynopsisLabs ,

The way @TheTimeSavingCo is designed is perfect.

But only a couple of improvements you can make. 

The first field(Primary field) of the Fuel Logs table can be used using Summary(formula), date(created) or AutoNumber.