UseCase3001 – Enroll in Subject
Initiating actor: Student
Other actors: Professor
Description: A student wants to enroll in a subject offered by their faculty. The system checks prerequisites, enrollment limits, and records the enrollment in the database.
Scenario:
- Student logs into the system and selects “Enroll in Subject.”
- System displays a list of subjects available for their faculty:
SELECT s.Id, s.Name, s.Semester, s.Credits FROM Subject s JOIN Faculty f ON s.Faculty_Id = f.Id JOIN Student st ON st.Faculty_Id = f.Id WHERE st.Id = :student_id;
- Student chooses a subject and clicks “Enroll.”
- System checks if the student is already enrolled:
SELECT * FROM Student_Subject WHERE Student_Id = :student_id AND Subject_Id = :subject_id;
- If not enrolled, system inserts enrollment record:
INSERT INTO Student_Subject(Student_Id, Subject_Id, Status, Enrollment_Date, Absences_Count) VALUES (:student_id, :subject_id, 'ENROLLED', CURRENT_DATE, 0);
- System confirms enrollment and updates student's schedule.
Last modified
3 weeks ago
Last modified on 02/04/26 12:51:19
Note:
See TracWiki
for help on using the wiki.
