Database: aircraft

Question: What are the total number of Domestic Passengers of airports that contain the word "London".
SQL: SELECT sum(Domestic_Passengers) FROM airport WHERE Airport_Name LIKE "%London%"

Question: What are the maximum and minimum number of transit passengers of all airports.
SQL: SELECT max(Transit_Passengers), min(Transit_Passengers) FROM airport

Question: List names of all pilot aged 30 or younger in descending alphabetical order.
SQL: SELECT Name FROM pilot WHERE Age  <=  30 ORDER BY Name DESC

Question: Please show the names of aircrafts associated with airport with name "London Gatwick".
SQL: SELECT T1.Aircraft FROM aircraft AS T1 JOIN airport_aircraft AS T2 ON T1.Aircraft_ID  =  T2.Aircraft_ID JOIN airport AS T3 ON T2.Airport_ID  =  T3.Airport_ID WHERE T3.Airport_Name  =  "London Gatwick"

Question: Please show the names and descriptions of aircrafts associated with airports that have a total number of passengers bigger than 10000000.
SQL: SELECT T1.Aircraft ,  T1.Description FROM aircraft AS T1 JOIN airport_aircraft AS T2 ON T1.Aircraft_ID  =  T2.Aircraft_ID JOIN airport AS T3 ON T2.Airport_ID  =  T3.Airport_ID WHERE T3.Total_Passengers  >  10000000

Question: What is the average total number of passengers of airports that are associated with aircraft "Robinson R-22"?
SQL: SELECT avg(T3.Total_Passengers) FROM aircraft AS T1 JOIN airport_aircraft AS T2 ON T1.Aircraft_ID  =  T2.Aircraft_ID JOIN airport AS T3 ON T2.Airport_ID  =  T3.Airport_ID WHERE T1.Aircraft  =  "Robinson R-22"

Question: List the name of the aircraft that has been named winning aircraft the most number of times.
SQL: SELECT T1.Aircraft FROM aircraft AS T1 JOIN MATCH AS T2 ON T1.Aircraft_ID  =  T2.Winning_Aircraft GROUP BY T2.Winning_Aircraft ORDER BY COUNT(*) DESC LIMIT 1

Question: List the names of aircrafts and the number of times it won matches.
SQL: SELECT T1.Aircraft,  COUNT(*) FROM aircraft AS T1 JOIN MATCH AS T2 ON T1.Aircraft_ID  =  T2.Winning_Aircraft GROUP BY T2.Winning_Aircraft

Question: List the names of aircrafts and that won matches at least twice.
SQL: SELECT T1.Aircraft FROM aircraft AS T1 JOIN MATCH AS T2 ON T1.Aircraft_ID  =  T2.Winning_Aircraft GROUP BY T2.Winning_Aircraft HAVING COUNT(*)  >=  2

Question: List the names of aircrafts and that did not win any match.
SQL: SELECT Aircraft FROM aircraft WHERE Aircraft_ID NOT IN (SELECT Winning_Aircraft FROM MATCH)

Question: Show the names of aircrafts that are associated with both an airport named "London Heathrow" and an airport named "London Gatwick"
SQL: SELECT T1.Aircraft FROM aircraft AS T1 JOIN airport_aircraft AS T2 ON T1.Aircraft_ID  =  T2.Aircraft_ID JOIN airport AS T3 ON T2.Airport_ID  =  T3.Airport_ID WHERE T3.Airport_Name  =  "London Heathrow" INTERSECT SELECT T1.Aircraft FROM aircraft AS T1 JOIN airport_aircraft AS T2 ON T1.Aircraft_ID  =  T2.Aircraft_ID JOIN airport AS T3 ON T2.Airport_ID  =  T3.Airport_ID WHERE T3.Airport_Name  =  "London Gatwick"

Question: Show all information on the airport that has the largest number of international passengers.
SQL: SELECT * FROM airport ORDER BY International_Passengers DESC LIMIT 1