Skip to content
Snippets Groups Projects

Database example data

2 files
+ 124
0
Compare changes
  • Side-by-side
  • Inline

Files

INSERT INTO Quarter (year, quarter, interest, availability, verifiable) VALUES
(2018, 1, 0, 0, 0),
(2018, 2, 0, 0, 0),
(2018, 3, 0, 0, 0),
(2018, 4, 0, 0, 0),
(2019, 1, 0, 0, 0);
INSERT INTO User (display_name, netid, student_number, first_name, last_name, email, tshirt_gender, tshirt_size, gdpr_accepted, gdpr_time, last_modified, created) VALUES
("displayname1", "netid1", "1111111", "firstname1", "lastname1", "student1@student.tudelft.nl", "M", "XL", 1, current_timestamp, current_timestamp, current_timestamp),
("displayname2", "netid2", "2222222", "firstname2", "lastname2", "student2@student.tudelft.nl", "M", "XL", 1, current_timestamp, current_timestamp, current_timestamp),
("displayname3", "netid3", "3333333", "firstname3", "lastname3", "student3@student.tudelft.nl", "M", "XL", 1, current_timestamp, current_timestamp, current_timestamp),
("displayname4", "netid4", "4444444", "firstname4", "lastname4", "student4@student.tudelft.nl", "M", "XL", 1, current_timestamp, current_timestamp, current_timestamp),
("displayname5", "netid5", "5555555", "firstname5", "lastname5", "student5@student.tudelft.nl", "M", "XL", 1, current_timestamp, current_timestamp, current_timestamp);
INSERT INTO Role (id, name) VALUES
(0, "ADMIN"),
(1, "STUDENT"),
(2, "STAFF"),
(3, "VERIFIER"),
(4, "SCHEDULER");
INSERT INTO User_Role (netid, role_id)
VALUES
("netid1", 1),
("netid1", 2),
("netid2", 2),
("netid3", 2),
("netid4", 2),
("netid5", 2),
("netid5", 3);
INSERT INTO CourseEdition (id, owner, course_code, name, teacher, study_year, year, quarter) VALUES
(1, "netid1", "CSE1000", "Mentoraat", "", 1, 2018, 1),
(2, "netid1", "CSE1300", "Reasoning and Logic", "", 1, 2018, 1),
(3, "netid1", "CSE1100", "Object-oriented programming", "", 1, 2018, 1),
(4, "netid1", "CSE1400", "Computer Organisation", "", 1, 2018, 1),
(5, "netid1", "CSE1200", "Calculus", "", 1, 2018, 2),
(6, "netid1", "CSE1305", "Algorithms and Data Structures", "", 1, 2018, 2),
(7, "netid1", "CSE1500", "Web and Database Technology", "", 1, 2018, 2),
(8, "netid1", "TI2216M", "Probability Theory and Statistics", "", 2, 2018, 1),
(9, "netid1", "TI2206", "Software Engineering Methods", "", 2, 2018, 1),
(10, "netid1", "TI2716-A", "Signal Processing", "", 2, 2018, 1),
(11, "netid1", "TI2716-B", "Digital Systems", "", 2, 2018, 1),
(12, "netid1", "TI2716-C", "Computational Intelligence", "", 2, 2018, 1),
(13, "netid1", "TI2306", "Algorithm Design", "", 2, 2018, 2),
(14, "netid1", "TI2506", "Information and Data Management", "", 2, 2018, 2),
(15, "netid1", "TI2716-B", "Image Processing", "", 2, 2018, 2),
(16, "netid1", "TI2726-B", "Embedded Software", "", 2, 2018, 2),
(17, "netid1", "TI2736-B", "Big Data Processing", "", 2, 2018, 2),
(18, "netid1", "TI3105TU", "Introduction to Python Programming (minor)", "", 3, 2018, 1),
(19, "netid1", "TI3110TU", "Algorithms and Data Structures (minor)", "", 3, 2018, 1),
(20, "netid1", "TI3115TU", "Software Engineering Methods (minor)", "", 3, 2018, 1),
(21, "netid1", "EWI3610TU", "Computer Graphics (minor)", "", 3, 2018, 2),
(22, "netid1", "EWI3615TU", "Computer Science Project (minor)", "", 3, 2018, 2),
(23, "netid1", "EWI3620TU", "Games Project (minor)", "", 3, 2018, 2),
(24, "netid1", "TI3125TU", "Web and Database Technology (minor)", "", 3, 2018, 2);
INSERT into PersonalPreference (netid, ce_id, last_year, v_rank) values
("netid1", 1, 0, 1),
("netid2", 1, 1, 1),
("netid3", 1, 0, 1),
("netid3", 2, 0, 1),
("netid4", 2, 1, 1);
INSERT INTO CoursePreference (netid, ce_id, p_rank) VALUES
("netid1", 1, 0),
("netid2", 1, 1),
("netid3", 1, 1);
INSERT INTO Slot (id, start_time, end_time) VALUES
(1, '10:00:00', '11:00:00'),
(2, '13:00:00', '14:00:00'),
(3, '16:00:00', '17:00:00');
INSERT INTO Timeslot (date, slot_id, year, quarter) VALUES
(CURRENT_DATE, 1, 2018, 1),
(CURRENT_DATE, 2, 2018, 1),
(CURRENT_DATE, 3, 2019, 1);
INSERT INTO availability (netid, date, slot_id) VALUES
("netid1", CURRENT_DATE, 1),
("netid1", CURRENT_DATE, 2),
("netid1", CURRENT_DATE, 3),
("netid2", CURRENT_DATE, 1),
("netid2", CURRENT_DATE, 2),
("netid2", CURRENT_DATE, 3),
("netid3", CURRENT_DATE, 1),
("netid3", CURRENT_DATE, 2),
("netid3", CURRENT_DATE, 3),
("netid4", CURRENT_DATE, 1),
("netid4", CURRENT_DATE, 2),
("netid4", CURRENT_DATE, 3);
INSERT INTO limits (netid, year, quarter, hour_limit, course_limit) VALUES
("netid1", 2018, 1, 10, 10),
("netid2", 2018, 1, 20, 20),
("netid3", 2018, 1, 30, 30),
("netid4", 2018, 1, 40, 40),
("netid5", 2018, 1, 50, 50);
INSERT INTO Lab (id, deleted) VALUES
(1, 0),
(2, 0),
(3, 0),
(4, 0),
(5, 0);
INSERT INTO LabSession (lab_id, ce_id, date, slot_id, num_ta) VALUES
(1, 1, CURRENT_DATE, 1, 1),
(1, 1, CURRENT_DATE, 2, 1),
(1, 2, CURRENT_DATE, 1, 2),
(2, 2, CURRENT_DATE, 2, 1);
INSERT INTO prerequisites (netid, ta_training, english_test, accepted, payscale) VALUES
("netid1", 0, 0, 1, null),
("netid2", 1, 1, 1, null),
("netid3", 2, 2, 2, 2),
("netid4", 1, 1, 2, 3),
("netid5", 2, 2, 0, 4);
Loading