PRAGMA foreign_keys = ON;

PRAGMA writable_schema = 1;
DELETE FROM sqlite_master WHERE type IN ("table", "index", "trigger");
PRAGMA writable_schema = 0;
VACUUM;

CREATE TABLE "singer" (
"Singer_ID" INT UNIQUE,
"Name" TEXT,
"Net_Worth_Millions" FLOAT,
PRIMARY KEY ("Singer_ID")
);

CREATE TABLE "song" (
"Song_ID" INT,
"Title" TEXT,
"Singer_ID" INT,
"Sales" FLOAT,
"Highest_Position" FLOAT,
PRIMARY KEY ("Song_ID"),
FOREIGN KEY ("Singer_ID") REFERENCES "singer"("Singer_ID")
);





INSERT INTO "singer" VALUES ("1", "Adele", "190.5");
INSERT INTO "singer" VALUES ("2", "Bruno Mars", "175.3");
INSERT INTO "singer" VALUES ("3", "Taylor Swift", "365.0");
INSERT INTO "singer" VALUES ("4", "Ed Sheeran", "220.7");
INSERT INTO "singer" VALUES ("5", "Newcomer Star", "0.5");
INSERT INTO "singer" VALUES ("6", "Legacy Artist", "500.0");
INSERT INTO "song" VALUES ("1", "Hello", "1", "120.5", "1");
INSERT INTO "song" VALUES ("2", "Rolling in the Deep", "1", "95.0", "2");
INSERT INTO "song" VALUES ("3", "Grenade", "2", "80.0", "1");
INSERT INTO "song" VALUES ("4", "Just the Way You Are", "2", "75.5", "3");
INSERT INTO "song" VALUES ("5", "Shake It Off", "3", "150.0", "1");
INSERT INTO "song" VALUES ("6", "Blank Space", "3", "140.0", "1");
INSERT INTO "song" VALUES ("7", "Shape of You", "4", "200.0", "1");
INSERT INTO "song" VALUES ("8", "Perfect", "4", "180.0", "2");
INSERT INTO "song" VALUES ("9", "Debut Hit", "5", "0.1", "50");
INSERT INTO "song" VALUES ("10", "Classic Hit", "6", "300.0", "1");
INSERT INTO "song" VALUES ("11", "Another Classic", "6", "250.0", "2");