human
Schema:
station (Station_ID, Name, Annual_entry_exit, Annual_interchanges, Total_Passengers, Location, Main_Services, Number_of_Platforms)
train (Train_ID, Name, Time, Service)
train_station (Train_ID, Station_ID)
Please answer with SQL.
assistant
Sure, I understand.
human
Show the names of the stations.
assistant
SELECT name FROM station;
human
Also show the main services for them.
assistant
SELECT name , main_services FROM station;
human
Order the results by the total number of passengers, descending.
assistant
SELECT name , main_services FROM station ORDER BY total_passengers DESC;
human
Only show the top three.
assistant
SELECT name , main_services FROM station ORDER BY total_passengers DESC LIMIT 3 ;