= 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:** 1. Student logs into the system and selects “Enroll in Subject.” 2. 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; }}} 3. Student chooses a subject and clicks “Enroll.” 4. System checks if the student is already enrolled: {{{ SELECT * FROM Student_Subject WHERE Student_Id = :student_id AND Subject_Id = :subject_id; }}} 5. 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); }}} 6. System confirms enrollment and updates student's schedule.