I have a database with three tables. Tbl 1 = Airlines, Tbl 2 = Destinations and Tbl 3 = Flights
The Flights table has four fields and is a many to many table. The fields are called Airline-Destination-Departure-Arrival. Airlines is a FK from the Airlines Table and Destinations is a Fk from the Destinations table.
The table records Airlines departure/arrival times on different routes.
I want to record the duration of each recorded flight.
I thought of adding a calculated field to the Flights Table and using it to subtract the departure time from the arrival time.
The problem is the Arrival time is the local time of the Destination and this can include UTC offsets such as UTC+2.
e.g if i fly from London to Helsinki the flight takes 3hrs. If I depart at 11:00am the time in London will be 2pm when I arrive but it will be 4pm local time as Finland is 2hrs ahead of London(UTC+2). If I was to use my calculated field using the local arrival time It would return an incorrect flight duration of 5hrs.
Another problem is that the UTC time differs in Winter by -1 and summer time by +1 in some countrys.
How can I set up my table to calculate the Flight duration correctly.
Thank you
The Flights table has four fields and is a many to many table. The fields are called Airline-Destination-Departure-Arrival. Airlines is a FK from the Airlines Table and Destinations is a Fk from the Destinations table.
The table records Airlines departure/arrival times on different routes.
I want to record the duration of each recorded flight.
I thought of adding a calculated field to the Flights Table and using it to subtract the departure time from the arrival time.
The problem is the Arrival time is the local time of the Destination and this can include UTC offsets such as UTC+2.
e.g if i fly from London to Helsinki the flight takes 3hrs. If I depart at 11:00am the time in London will be 2pm when I arrive but it will be 4pm local time as Finland is 2hrs ahead of London(UTC+2). If I was to use my calculated field using the local arrival time It would return an incorrect flight duration of 5hrs.
Another problem is that the UTC time differs in Winter by -1 and summer time by +1 in some countrys.
How can I set up my table to calculate the Flight duration correctly.
Thank you