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 "Player" (
"id" INT,
"player_api_id" INT UNIQUE,
"player_name" TEXT,
"player_fifa_api_id" INT UNIQUE,
"birthday" TEXT,
PRIMARY KEY ("id")
);

CREATE TABLE "Player_Attributes" (
"id" INT,
"date" TEXT,
"overall_rating" INT,
PRIMARY KEY ("id")
);



INSERT INTO "Player" VALUES ("1", "1001", "John Smith", "5001", "1970-10-05");
INSERT INTO "Player" VALUES ("2", "1002", "Michael Johnson", "5002", "1970-10-20");
INSERT INTO "Player" VALUES ("3", "1003", "David Brown", "5003", "1970-09-15");
INSERT INTO "Player" VALUES ("4", "1004", "Chris Green", "5004", "1971-10-10");
INSERT INTO "Player" VALUES ("5", "1005", "James White", "5005", "1970-10-30");
INSERT INTO "Player" VALUES ("6", "1006", "Robert Black", "5006", "1969-10-25");
INSERT INTO "Player" VALUES ("7", "1007", "William Blue", "5007", "1970-11-01");
INSERT INTO "Player" VALUES ("8", "1008", "Thomas Gray", "5008", "1970-10-01");
INSERT INTO "Player" VALUES ("9", "1009", "Daniel Red", "5009", "1970-08-22");
INSERT INTO "Player" VALUES ("10", "1010", "Matthew Yellow", "5010", "1970-10-15");
INSERT INTO "Player_Attributes" VALUES ("1", "2000-01-01", "75");
INSERT INTO "Player_Attributes" VALUES ("2", "2000-01-01", "80");
INSERT INTO "Player_Attributes" VALUES ("3", "2000-01-01", "78");
INSERT INTO "Player_Attributes" VALUES ("4", "2000-01-01", "82");
INSERT INTO "Player_Attributes" VALUES ("5", "2000-01-01", "77");
INSERT INTO "Player_Attributes" VALUES ("6", "2000-01-01", "74");
INSERT INTO "Player_Attributes" VALUES ("7", "2000-01-01", "79");
INSERT INTO "Player_Attributes" VALUES ("8", "2000-01-01", "76");
INSERT INTO "Player_Attributes" VALUES ("9", "2000-01-01", "73");
INSERT INTO "Player_Attributes" VALUES ("10", "2000-01-01", "81");