Hi! Could we please enable some services and cookies to improve your experience and our website?

SQLize | PHPize | SQLtest

Online Sandbox for SQL and PHP: Write, Run, Test, and Share SQL Queries and PHP Code

A A A
Login    Share code      Blog   FAQ
Copy Format Clear
Select airport_code , AVG(sum(cdep)) from (Select departure_airport as airport, count(departure_airport) cdep from flights group by departure_airport union all Select arrival_airport , count(arrival_airport) cdep from flights group by arrival_airport) l left join airports_data a on a.airport_code = l.airport group by airport

Stuck with a problem? Got Error? Ask AI support!

Copy Clear