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 "Professionals" (
"professional_id" INT UNIQUE,
"city" VARCHAR(50),
"state" VARCHAR(20),
"last_name" VARCHAR(50),
"cell_number" VARCHAR(20),
PRIMARY KEY ("professional_id")
);

CREATE TABLE "Treatments" (
"treatment_id" INT,
"dog_id" INT,
"professional_id" INT,
"treatment_type_code" VARCHAR(10),
PRIMARY KEY ("treatment_id"),
FOREIGN KEY ("professional_id") REFERENCES "Professionals"("professional_id")
);





INSERT INTO "Professionals" VALUES ("1", "Indianapolis", "Indiana", "Smith", "317-555-1234");
INSERT INTO "Professionals" VALUES ("2", "Chicago", "Illinois", "Johnson", "312-555-5678");
INSERT INTO "Professionals" VALUES ("3", "Fort Wayne", "Indiana", "Williams", "260-555-8765");
INSERT INTO "Professionals" VALUES ("4", "Columbus", "Ohio", "Brown", "614-555-4321");
INSERT INTO "Professionals" VALUES ("5", "Evansville", "Indiana", "Jones", "812-555-3456");
INSERT INTO "Professionals" VALUES ("6", "Cincinnati", "Ohio", "Garcia", "513-555-7890");
INSERT INTO "Professionals" VALUES ("7", "Naperville", "Illinois", "Miller", "630-555-2345");
INSERT INTO "Professionals" VALUES ("8", "Bloomington", "Indiana", "Davis", "812-555-6789");
INSERT INTO "Professionals" VALUES ("9", "Louisville", "Kentucky", "Rodriguez", "502-555-9876");
INSERT INTO "Professionals" VALUES ("10", "Indianapolis", "Indiana", "Martinez", "317-555-6543");
INSERT INTO "Treatments" VALUES ("1", "101", "2", "Vaccination");
INSERT INTO "Treatments" VALUES ("2", "102", "2", "Checkup");
INSERT INTO "Treatments" VALUES ("3", "103", "2", "Deworming");
INSERT INTO "Treatments" VALUES ("4", "104", "4", "Vaccination");
INSERT INTO "Treatments" VALUES ("5", "105", "4", "Checkup");
INSERT INTO "Treatments" VALUES ("6", "106", "6", "Surgery");
INSERT INTO "Treatments" VALUES ("7", "107", "7", "Checkup");
INSERT INTO "Treatments" VALUES ("8", "108", "7", "Vaccination");
INSERT INTO "Treatments" VALUES ("9", "109", "7", "Deworming");
INSERT INTO "Treatments" VALUES ("10", "110", "9", "Checkup");
INSERT INTO "Treatments" VALUES ("11", "111", "9", "Vaccination");
INSERT INTO "Treatments" VALUES ("12", "112", "10", "Surgery");
INSERT INTO "Treatments" VALUES ("13", "113", "10", "Checkup");
INSERT INTO "Treatments" VALUES ("14", "114", "10", "Vaccination");
INSERT INTO "Treatments" VALUES ("15", "115", "1", "Checkup");
INSERT INTO "Treatments" VALUES ("16", "116", "1", "Vaccination");
INSERT INTO "Treatments" VALUES ("17", "117", "1", "Deworming");