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 "Examination" (
"ID" INT,
"RVVT" TEXT,
"LAC" TEXT,
FOREIGN KEY ("ID") REFERENCES "Patient"("ID")
);

CREATE TABLE "Patient" (
"ID" INT UNIQUE,
"SEX" TEXT,
"Birthday" DATE,
PRIMARY KEY ("ID")
);



INSERT INTO "Patient" VALUES ("1", "M", "1980-05-20");
INSERT INTO "Patient" VALUES ("2", "F", "1995-11-15");
INSERT INTO "Patient" VALUES ("3", "M", "1970-01-01");
INSERT INTO "Patient" VALUES ("4", "F", "2000-12-31");
INSERT INTO "Patient" VALUES ("5", "M", "1965-07-07");
INSERT INTO "Patient" VALUES ("6", "F", "1988-03-22");
INSERT INTO "Patient" VALUES ("7", "M", "1999-09-09");
INSERT INTO "Patient" VALUES ("8", "F", "1975-06-30");
INSERT INTO "Patient" VALUES ("9", "M", "1982-02-28");
INSERT INTO "Patient" VALUES ("10", "F", "1990-10-10");
INSERT INTO "Examination" VALUES ("1", "+", "neg");
INSERT INTO "Examination" VALUES ("1", "-", "pos");
INSERT INTO "Examination" VALUES ("2", "-", "neg");
INSERT INTO "Examination" VALUES ("3", "+", "pos");
INSERT INTO "Examination" VALUES ("3", "+", "neg");
INSERT INTO "Examination" VALUES ("4", "-", "neg");
INSERT INTO "Examination" VALUES ("5", "+", "pos");
INSERT INTO "Examination" VALUES ("6", "-", "pos");
INSERT INTO "Examination" VALUES ("7", "-", "neg");
INSERT INTO "Examination" VALUES ("8", "+", "neg");
INSERT INTO "Examination" VALUES ("8", "-", "pos");
INSERT INTO "Examination" VALUES ("9", "-", "neg");