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 "Courses" (
"course_id" INT,
"course_name" VARCHAR(255),
"course_description" VARCHAR(255),
PRIMARY KEY ("course_id")
);

CREATE TABLE "Degree_Programs" (
"degree_program_id" INT,
"department_id" INT,
"degree_summary_name" VARCHAR(255),
"degree_summary_description" VARCHAR(255),
PRIMARY KEY ("degree_program_id"),
FOREIGN KEY ("department_id") REFERENCES "Departments"("department_id")
);

CREATE TABLE "Departments" (
"department_id" INT UNIQUE,
"department_name" VARCHAR(255),
PRIMARY KEY ("department_id")
);





INSERT INTO "Departments" VALUES ("1", "Computer Science");
INSERT INTO "Departments" VALUES ("2", "Mathematics");
INSERT INTO "Departments" VALUES ("3", "Physics");
INSERT INTO "Departments" VALUES ("4", "History");
INSERT INTO "Departments" VALUES ("5", "Biology");
INSERT INTO "Degree_Programs" VALUES ("101", "1", "BSc Computer Science", "Bachelor of Science in Computer Science");
INSERT INTO "Degree_Programs" VALUES ("102", "1", "MSc Computer Science", "Master of Science in Computer Science");
INSERT INTO "Degree_Programs" VALUES ("103", "2", "BSc Mathematics", "Bachelor of Science in Mathematics");
INSERT INTO "Degree_Programs" VALUES ("104", "2", "MSc Mathematics", "Master of Science in Mathematics");
INSERT INTO "Degree_Programs" VALUES ("105", "3", "BSc Physics", "Bachelor of Science in Physics");
INSERT INTO "Degree_Programs" VALUES ("106", "4", "BA History", "Bachelor of Arts in History");
INSERT INTO "Degree_Programs" VALUES ("107", "5", "BSc Biology", "Bachelor of Science in Biology");
INSERT INTO "Degree_Programs" VALUES ("108", "5", "MSc Biology", "Master of Science in Biology");
INSERT INTO "Degree_Programs" VALUES ("109", "1", "PhD Computer Science", "Doctor of Philosophy in Computer Science");
INSERT INTO "Courses" VALUES ("201", "Intro to Programming", "Basic programming concepts in Python");
INSERT INTO "Courses" VALUES ("202", "Data Structures", "Study of data organization and algorithms");
INSERT INTO "Courses" VALUES ("203", "Calculus I", "Introduction to differential and integral calculus");
INSERT INTO "Courses" VALUES ("204", "Linear Algebra", "Matrix theory and linear algebra concepts");
INSERT INTO "Courses" VALUES ("205", "Classical Mechanics", "Fundamentals of Newtonian mechanics");
INSERT INTO "Courses" VALUES ("206", "Modern History", "History from 1900 to present");
INSERT INTO "Courses" VALUES ("207", "Genetics", "Introduction to genetics and heredity");
INSERT INTO "Courses" VALUES ("208", "Advanced Programming", "Advanced programming techniques and paradigms");
INSERT INTO "Courses" VALUES ("209", "Quantum Physics", "Introduction to quantum theory");
INSERT INTO "Courses" VALUES ("210", "Abstract Algebra", "Group theory and ring theory basics");