
CREATE TABLE manager (
	"Manager_ID" INTEGER, 
	"Name" TEXT, 
	"Country" TEXT, 
	"Working_year_starts" TEXT, 
	"Age" INTEGER, 
	"Level" INTEGER, 
	PRIMARY KEY ("Manager_ID")
)


CREATE TABLE railway (
	"Railway_ID" INTEGER, 
	"Railway" TEXT, 
	"Builder" TEXT, 
	"Built" TEXT, 
	"Wheels" TEXT, 
	"Location" TEXT, 
	"ObjectNumber" TEXT, 
	PRIMARY KEY ("Railway_ID")
)


CREATE TABLE railway_manage (
	"Railway_ID" INTEGER, 
	"Manager_ID" INTEGER, 
	"From_Year" TEXT, 
	PRIMARY KEY ("Railway_ID", "Manager_ID"), 
	FOREIGN KEY("Manager_ID") REFERENCES manager ("Manager_ID"), 
	FOREIGN KEY("Railway_ID") REFERENCES railway ("Railway_ID")
)


CREATE TABLE train (
	"Train_ID" INTEGER, 
	"Train_Num" TEXT, 
	"Name" TEXT, 
	"From" TEXT, 
	"Arrival" TEXT, 
	"Railway_ID" INTEGER, 
	PRIMARY KEY ("Train_ID"), 
	FOREIGN KEY("Railway_ID") REFERENCES railway ("Railway_ID")
)

CREATE TABLE manager (
	"Manager_ID" INTEGER, 
	"Name" TEXT, 
	"Country" TEXT, 
	"Working_year_starts" TEXT, 
	"Age" INTEGER, 
	"Level" INTEGER, 
	PRIMARY KEY ("Manager_ID")
)

/*
2 rows from manager table:
Manager_ID	Name	Country	Working_year_starts	Age	Level
1	Ben Curtis	United States	2003	45	5
2	Todd Hamilton	United States	2004	55	5
*/


CREATE TABLE railway (
	"Railway_ID" INTEGER, 
	"Railway" TEXT, 
	"Builder" TEXT, 
	"Built" TEXT, 
	"Wheels" TEXT, 
	"Location" TEXT, 
	"ObjectNumber" TEXT, 
	PRIMARY KEY ("Railway_ID")
)

/*
2 rows from railway table:
Railway_ID	Railway	Builder	Built	Wheels	Location	ObjectNumber
1	SECR	SECR Ashford	1901	4-4-0	York	1975-7006
2	MR	MR Derby	1902 Midland Railway 1000 was rebuilt in 1914.	4-4-0	Bo'ness	1975-7018
*/


CREATE TABLE railway_manage (
	"Railway_ID" INTEGER, 
	"Manager_ID" INTEGER, 
	"From_Year" TEXT, 
	PRIMARY KEY ("Railway_ID", "Manager_ID"), 
	FOREIGN KEY("Manager_ID") REFERENCES manager ("Manager_ID"), 
	FOREIGN KEY("Railway_ID") REFERENCES railway ("Railway_ID")
)

/*
2 rows from railway_manage table:
Railway_ID	Manager_ID	From_Year
8	1	2010
9	2	2011
*/


CREATE TABLE train (
	"Train_ID" INTEGER, 
	"Train_Num" TEXT, 
	"Name" TEXT, 
	"From" TEXT, 
	"Arrival" TEXT, 
	"Railway_ID" INTEGER, 
	PRIMARY KEY ("Train_ID"), 
	FOREIGN KEY("Railway_ID") REFERENCES railway ("Railway_ID")
)

/*
2 rows from train table:
Train_ID	Train_Num	Name	From	Arrival	Railway_ID
1	51195	Wardha-Ballarshah Pass	Wardha	08:54	1
2	12139	Sewagram Exp	Mumbai CST	09:08	1
*/
List the object number of railways that do not have any trains.
SELECT ObjectNumber FROM railway WHERE Railway_ID NOT IN (SELECT Railway_ID FROM train)
[{'ObjectNumber': '1978-7025'}, {'ObjectNumber': '1978-7026'}, {'ObjectNumber': '1978-7027'}]