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 "car_makers" (
"Id" INT,
"Maker" TEXT,
PRIMARY KEY ("Id")
);

CREATE TABLE "car_names" (
"MakeId" INT,
"Model" TEXT,
PRIMARY KEY ("MakeId")
);

CREATE TABLE "cars_data" (
"Id" INT,
"Cylinders" INT,
"Horsepower" TEXT,
"Accelerate" FLOAT,
PRIMARY KEY ("Id")
);





INSERT INTO "car_makers" VALUES ("1", "Toyota");
INSERT INTO "car_makers" VALUES ("2", "Ford");
INSERT INTO "car_makers" VALUES ("3", "Honda");
INSERT INTO "car_makers" VALUES ("4", "Chevrolet");
INSERT INTO "car_makers" VALUES ("5", "BMW");
INSERT INTO "car_names" VALUES ("1", "Corolla");
INSERT INTO "car_names" VALUES ("2", "Mustang");
INSERT INTO "car_names" VALUES ("3", "Civic");
INSERT INTO "car_names" VALUES ("4", "Camaro");
INSERT INTO "car_names" VALUES ("5", "M3");
INSERT INTO "cars_data" VALUES ("1", "4", "132", "8.5");
INSERT INTO "cars_data" VALUES ("2", "6", "250", "6.2");
INSERT INTO "cars_data" VALUES ("3", "8", "450", "4.1");
INSERT INTO "cars_data" VALUES ("4", "4", "140", "7.9");
INSERT INTO "cars_data" VALUES ("5", "6", "300", "5.8");
INSERT INTO "cars_data" VALUES ("6", "8", "420", "4.5");
INSERT INTO "cars_data" VALUES ("7", "3", "100", "9.0");
INSERT INTO "cars_data" VALUES ("8", "3", "110", "8.7");
INSERT INTO "cars_data" VALUES ("9", "12", "600", "3.9");
INSERT INTO "cars_data" VALUES ("10", "12", "580", "4.2");
INSERT INTO "cars_data" VALUES ("11", "4", "135", "8.0");
INSERT INTO "cars_data" VALUES ("12", "6", "280", "6.0");