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 "orchestra" (
"Orchestra_ID" INT,
"Major_Record_Format" TEXT,
PRIMARY KEY ("Orchestra_ID")
);

CREATE TABLE "performance" (
"Performance_ID" INT,
"Type" TEXT,
"Weekly_rank" TEXT,
"Share" TEXT,
PRIMARY KEY ("Performance_ID")
);

CREATE TABLE "show" (
"Attendance" FLOAT
);





INSERT INTO "orchestra" VALUES ("1", "Vinyl");
INSERT INTO "orchestra" VALUES ("2", "Digital");
INSERT INTO "orchestra" VALUES ("3", "CD");
INSERT INTO "orchestra" VALUES ("4", "Streaming");
INSERT INTO "orchestra" VALUES ("5", "Cassette");
INSERT INTO "performance" VALUES ("1", "Preliminary", "1", "15.5");
INSERT INTO "performance" VALUES ("2", "Semi-final", "2", "0");
INSERT INTO "performance" VALUES ("3", "Live final", "1", "25.0");
INSERT INTO "performance" VALUES ("4", "Preliminary", "3", "7.25");
INSERT INTO "performance" VALUES ("5", "Semi-final", "4", "0.0");
INSERT INTO "performance" VALUES ("6", "Preliminary", "5", "100");
INSERT INTO "performance" VALUES ("7", "Live final", "2", "30.75");
INSERT INTO "performance" VALUES ("8", "Semi-final", "6", "0.0001");
INSERT INTO "performance" VALUES ("9", "Preliminary", "7", "50");
INSERT INTO "performance" VALUES ("10", "Semi-final", "8", "null");
INSERT INTO "performance" VALUES ("11", "Preliminary", "9", "5");
INSERT INTO "performance" VALUES ("12", "Semi-final", "10", "0.5");
INSERT INTO "show" VALUES ("1000.0");
INSERT INTO "show" VALUES ("500.5");
INSERT INTO "show" VALUES ("0.0");
INSERT INTO "show" VALUES ("250.25");
INSERT INTO "show" VALUES ("750.75");