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 "Charges" (
"charge_id" INT,
"charge_type" VARCHAR(10),
"charge_amount" DECIMAL(19, 4),
PRIMARY KEY ("charge_id")
);

CREATE TABLE "Treatment_Types" (
"treatment_type_code" VARCHAR(10),
"treatment_type_description" VARCHAR(80),
PRIMARY KEY ("treatment_type_code")
);

CREATE TABLE "Treatments" (
"treatment_id" INT,
"treatment_type_code" VARCHAR(10),
"cost_of_treatment" DECIMAL(19, 4),
PRIMARY KEY ("treatment_id"),
FOREIGN KEY ("treatment_type_code") REFERENCES "Treatment_Types"("treatment_type_code")
);





INSERT INTO "Charges" VALUES ("1", "Boarding", "50.00");
INSERT INTO "Charges" VALUES ("2", "Grooming", "75.50");
INSERT INTO "Charges" VALUES ("3", "Training", "120.00");
INSERT INTO "Charges" VALUES ("4", "Daycare", "30.00");
INSERT INTO "Charges" VALUES ("5", "Medical", "250.75");
INSERT INTO "Charges" VALUES ("6", "Food", "25.00");
INSERT INTO "Charges" VALUES ("7", "Boarding", "60.00");
INSERT INTO "Charges" VALUES ("8", "Training", "150.00");
INSERT INTO "Charges" VALUES ("9", "Medical", "300.00");
INSERT INTO "Charges" VALUES ("10", "Grooming", "80.00");