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,
"Birth_Year" FLOAT,
PRIMARY KEY ("Singer_ID")
);

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





INSERT INTO "singer" VALUES ("1", "Adele", "1988.0");
INSERT INTO "singer" VALUES ("2", "Ed Sheeran", "1991.0");
INSERT INTO "singer" VALUES ("3", "Taylor Swift", "1989.0");
INSERT INTO "singer" VALUES ("4", "Beyoncé", "1981.0");
INSERT INTO "singer" VALUES ("5", "Justin Bieber", "1994.0");
INSERT INTO "singer" VALUES ("6", "Rihanna", "1988.0");
INSERT INTO "singer" VALUES ("7", "Drake", "1986.0");
INSERT INTO "singer" VALUES ("8", "Ariana Grande", "1993.0");
INSERT INTO "singer" VALUES ("9", "Bruno Mars", "1985.0");
INSERT INTO "singer" VALUES ("10", "Katy Perry", "1984.0");
INSERT INTO "song" VALUES ("1", "Hello", "1", "30000000.0");
INSERT INTO "song" VALUES ("2", "Rolling in the Deep", "1", "25000000.0");
INSERT INTO "song" VALUES ("3", "Someone Like You", "1", "20000000.0");
INSERT INTO "song" VALUES ("4", "Shape of You", "2", "40000000.0");
INSERT INTO "song" VALUES ("5", "Thinking Out Loud", "2", "35000000.0");
INSERT INTO "song" VALUES ("6", "Bad Habits", "2", "15000000.0");
INSERT INTO "song" VALUES ("7", "Blank Space", "3", "28000000.0");
INSERT INTO "song" VALUES ("8", "Shake It Off", "3", "27000000.0");
INSERT INTO "song" VALUES ("9", "Love Story", "3", "22000000.0");
INSERT INTO "song" VALUES ("10", "Single Ladies", "4", "18000000.0");
INSERT INTO "song" VALUES ("11", "Halo", "4", "15000000.0");
INSERT INTO "song" VALUES ("12", "Sorry", "5", "26000000.0");
INSERT INTO "song" VALUES ("13", "What Do You Mean?", "5", "24000000.0");
INSERT INTO "song" VALUES ("14", "Umbrella", "6", "19000000.0");
INSERT INTO "song" VALUES ("15", "Work", "6", "17000000.0");
INSERT INTO "song" VALUES ("16", "Hotline Bling", "7", "21000000.0");
INSERT INTO "song" VALUES ("17", "God's Plan", "7", "23000000.0");
INSERT INTO "song" VALUES ("18", "Thank U, Next", "8", "16000000.0");
INSERT INTO "song" VALUES ("19", "7 Rings", "8", "14000000.0");
INSERT INTO "song" VALUES ("20", "Uptown Funk", "9", "29000000.0");
INSERT INTO "song" VALUES ("21", "Locked Out of Heaven", "9", "20000000.0");
INSERT INTO "song" VALUES ("22", "Roar", "10", "25000000.0");
INSERT INTO "song" VALUES ("23", "Firework", "10", "23000000.0");
INSERT INTO "song" VALUES ("24", "One Song Wonder", "10", "5000000.0");
INSERT INTO "song" VALUES ("25", "Another One Song Wonder", "10", "4000000.0");
INSERT INTO "song" VALUES ("26", "Single Hit", "1", "1000000.0");