Changes between Version 8 and Version 9 of P1
- Timestamp:
- 06/15/26 12:56:04 (36 hours ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
P1
v8 v9 9 9 10 10 11 == Data Requirements 12 • University: This entity stores information about universities. We need it to know which faculties , professors, and studentsbelong to which university.11 == Data Requirements == 12 • University: This entity stores information about universities. We need it to know which faculties belong to which university. 13 13 14 º Candidate keys: Id (primary key).14 º Candidate keys: Id (primary key). 15 15 16 º Attributes:16 º Attributes: 17 17 18 Id – number, required, unique18 Id – number, required, unique 19 19 20 Name – text, required, max 255 characters20 Name – text, required, max 255 characters 21 21 22 Location – text, optional, max 255 characters22 Location – text, optional, max 255 characters 23 23 24 isprivate – boolean, required24 isprivate – boolean, required 25 25 26 26 ---- … … 28 28 • Faculty: Represents a faculty inside a university. It helps organize students, professors, and subjects within that faculty. Each faculty belongs to one university. 29 29 30 º Candidate keys: Id (primary key).30 º Candidate keys: Id (primary key). 31 31 32 º Attributes:32 º Attributes: 33 33 34 Id – number, required, unique34 Id – number, required, unique 35 35 36 Name – text, required, max 255 characters36 Name – text, required, max 255 characters 37 37 38 Location – text, optional, max 255 characters38 Location – text, optional, max 255 characters 39 39 40 Study_field – text, optional, max 255 characters40 Study_field – text, optional, max 255 characters 41 41 42 University_Id – number, required, foreign key to University 42 University_Id – number, required, foreign key to University 43 44 ---- 45 • Professor: This entity stores professors. Each professor works in a specific faculty, can guide students through advice sessions, and is assigned to teach subjects inside student enrollments. 46 47 º Candidate keys: Id (primary key). 48 49 º Attributes: 50 51 Id – number, required, unique 52 53 Name – text, required, max 255 characters 54 55 Surname – text, optional, max 255 characters 56 57 Age – number, optional, 25–100 58 59 Faculty_Id – number, required, foreign key to Faculty 43 60 44 61 ---- 45 62 63 • Student: This entity stores students. Each student belongs to a faculty, can enroll in subjects, and can interact with professors during advice sessions. 46 64 47 • Professor: This entity stores professors. Each professor works in a faculty and can teach subjects or advise students.65 º Candidate keys: Id (primary key). 48 66 49 º Candidate keys: Id (primary key)67 º Attributes: 50 68 51 º Attributes:69 Id – number, required, unique 52 70 53 Id – number, required, unique71 Name – text, required, max 255 characters 54 72 55 Name – text, required, max 255 characters73 Surname – text, optional, max 255 characters 56 74 57 Surname– text, optional, max 255 characters75 Location – text, optional, max 255 characters 58 76 59 Age – number, optional, 25–10077 Index – number, required, unique 60 78 61 Faculty_Id – number, required, foreign key to Faculty79 Faculty_Id – number, required, foreign key to Faculty 62 80 63 81 ---- 64 82 65 • S tudent: This entity stores students. Each student belongs to a faculty and can enroll in many subjects. They can also have a professor as their adviser.83 • Subject: This entity stores courses or subjects offered by a faculty. Students can enroll in these subjects. 66 84 67 º Candidate keys: Id (primary key).85 º Candidate keys: Id (primary key). 68 86 69 º Attributes:87 º Attributes: 70 88 71 Id – number, required, unique89 Id – number, required, unique 72 90 73 Name – text, required, max 255 characters91 Name – text, required, max 255 characters 74 92 75 Surname – text, optional, max 255 characters93 Semester – text, optional, e.g., "Fall", "Spring" 76 94 77 Location – text, optional, max 255 characters95 Credits – number, required, 1–15 78 96 79 Index – number, required, unique 80 81 Faculty_Id – number, required, foreign key to Faculty 82 83 Professor_Id – number, optional, foreign key to Professor 97 Faculty_Id – number, required, foreign key to Faculty 84 98 85 99 ---- 86 100 87 • S ubject: This entity stores courses or subjects. Each subject belongs to a faculty and is taught by a professor. Students can enroll in subjects.101 • Student_Subject: This entity represents a specific student enrollment in a subject. It tracks grades, attendance, and status. It also links the specific professor who teaches this instance of the course. 88 102 89 º Candidate keys: Id (primary key)103 º Candidate keys: ssId (primary key). 90 104 91 º Attributes:105 º Attributes: 92 106 93 Id – number, required, unique107 ssId – number, required, unique 94 108 95 Name – text, required, max 255 characters109 Final_Grade – number, optional, 6–10 96 110 97 Semester – text, optional, e.g., "Fall", "Spring"111 Status – text, optional, e.g., "Enrolled", "Passed", "Failed" 98 112 99 Credits – number, required, 1–15113 Enrollment_Date – date, required 100 114 101 Faculty_Id – number, required, foreign key to Faculty115 Absence_Count – number, optional, 0–100 102 116 103 Professor_Id – number, required, foreign key to Professor117 Student_Id – number, required, foreign key to Student 104 118 105 ---- 119 Subject_Id – number, required, foreign key to Subject 106 120 107 • Student_Subject: This entity shows which students are enrolled in which subjects. It also stores their grades, attendance, and enrollment status. 108 109 º Candidate keys: ssId (primary key) 110 111 º Attributes: 112 113 Final_Grade – number, optional, 6–10 or pass/fail 114 115 Status – text, optional, e.g., "Enrolled", "Passed", "Failed" 116 117 Enrollment_Date – date, required 118 119 Absence_Count – number, optional, 0–100 120 121 Student_Id – number, required, foreign key to Student 122 123 Subject_Id – number, required, foreign key to Subject 124 121 Professor_Id – number, required, foreign key to Professor 125 122 126 123 == Entity-Relationship Model History
