UseCase3001Implementation – Enroll in Subject
Initiating actor: Student
Other actors: None
Description: Student enrolls in a subject offered by their faculty and selects a specific professor teaching that course instance.
Scenario:
- System displays Student Menu.
- Student selects Enroll in Subject.
- System lists all students → Student selects their Student ID.
- System lists available subjects for the student's faculty:
SELECT s.Id, s.Name FROM Subject s JOIN Student st ON s.Faculty_Id = st.Faculty_Id WHERE st.Id = ?;
Student selects a Subject ID.
- System lists all available professors for the chosen subject:
SELECT p.Id, p.Name, p.Surname FROM Professor p JOIN Subject s ON p.Faculty_Id = s.Faculty_Id WHERE s.Id = ?;
Student selects a Professor ID.
- System checks if the student is already enrolled in this subject:
SELECT * FROM Student_Subject WHERE Student_Id = ? AND Subject_Id = ?;
- If not enrolled, system inserts the new enrollment record into the database:
INSERT INTO Student_Subject(Student_Id, Subject_Id, Professor_Id, Status, Enrollment_Date, Absences_Count) VALUES (?, ?, ?, 'PASSED', CURRENT_DATE, 0);
- System confirms successful enrollment.
Last modified
2 days ago
Last modified on 06/15/26 14:35:42
Attachments (5)
- enrollSubject1.jpg (132.6 KB ) - added by 4 months ago.
- enrollSubject1.png (83.8 KB ) - added by 2 days ago.
- enrollSubject2.png (187.6 KB ) - added by 2 days ago.
- enrollSubject3.png (163.8 KB ) - added by 2 days ago.
- enrollSubject4.png (89.5 KB ) - added by 2 days ago.
Download all attachments as: .zip
Note:
See TracWiki
for help on using the wiki.




