
CREATE TABLE mission (
	"Mission_ID" INTEGER, 
	"Ship_ID" INTEGER, 
	"Code" TEXT, 
	"Launched_Year" INTEGER, 
	"Location" TEXT, 
	"Speed_knots" INTEGER, 
	"Fate" TEXT, 
	PRIMARY KEY ("Mission_ID"), 
	FOREIGN KEY("Ship_ID") REFERENCES ship ("Ship_ID")
)


CREATE TABLE ship (
	"Ship_ID" INTEGER, 
	"Name" TEXT, 
	"Type" TEXT, 
	"Nationality" TEXT, 
	"Tonnage" INTEGER, 
	PRIMARY KEY ("Ship_ID")
)

CREATE TABLE mission (
	"Mission_ID" INTEGER, 
	"Ship_ID" INTEGER, 
	"Code" TEXT, 
	"Launched_Year" INTEGER, 
	"Location" TEXT, 
	"Speed_knots" INTEGER, 
	"Fate" TEXT, 
	PRIMARY KEY ("Mission_ID"), 
	FOREIGN KEY("Ship_ID") REFERENCES ship ("Ship_ID")
)

/*
2 rows from mission table:
Mission_ID	Ship_ID	Code	Launched_Year	Location	Speed_knots	Fate
1	1	VMV-1	1930	Germany	25	Decommissioned 1950
2	2	VMV-2	1930	Germany	25	Decommissioned 1950
*/


CREATE TABLE ship (
	"Ship_ID" INTEGER, 
	"Name" TEXT, 
	"Type" TEXT, 
	"Nationality" TEXT, 
	"Tonnage" INTEGER, 
	PRIMARY KEY ("Ship_ID")
)

/*
2 rows from ship table:
Ship_ID	Name	Type	Nationality	Tonnage
1	Corbridge	Cargo ship	United Kingdom	3687
2	Farringford	Battle ship	United States	3146
*/
List the name of ships in ascending order of tonnage.
SELECT Name FROM ship ORDER BY Tonnage ASC
[{'Name': 'Ariadne'}, {'Name': 'Farringford'}, {'Name': 'Author'}, {'Name': 'Trader'}, {'Name': 'Dromonby'}, {'Name': 'Corbridge'}, {'Name': 'Clan McTavish'}, {'Name': 'Appam'}]