TASK #230 · Medium · AmadeusAverage Departure Delay per Airline
Your brief
In the flights table scheduled_departure is the scheduled
departure time and actual_departure is the actual one. The delay of a
flight is the difference between them in minutes; if the flight left earlier
than scheduled, its delay is 0.
Write a query that for every airline returns airline_name and the average delay avg_delay_min of its operated flights (status = 'Departed'), rounded to two decimals.
Write a query that for every airline returns airline_name and the average delay avg_delay_min of its operated flights (status = 'Departed'), rounded to two decimals.
Ctrl / ⌘ + ↵
Result
Write a query and run it to see the results.
Schema
airlinesairline_code, airline_name, countryflightsflight_id, flight_number, airline_code, origin, destination, scheduled_departure, actual_departure, statusbookingsbooking_id, flight_id, booking_date, price, status