| | 1 | = UseCase2002 – Advise Student |
| | 2 | |
| | 3 | **Initiating actor:** Professor |
| | 4 | **Other actors:** Student |
| | 5 | |
| | 6 | **Description:** |
| | 7 | A professor becomes an academic advisor to a student for a specific period. |
| | 8 | |
| | 9 | **Scenario:** |
| | 10 | |
| | 11 | 1. Professor selects “Start Advising Student” |
| | 12 | |
| | 13 | 2. System shows list of students in professor’s faculty: |
| | 14 | {{{ |
| | 15 | SELECT st.Id, st.Name, st.Surname |
| | 16 | FROM Student st |
| | 17 | JOIN Faculty f ON st.Faculty_Id = f.Id |
| | 18 | JOIN Professor p ON p.Faculty_Id = f.Id |
| | 19 | WHERE p.Id = :professor_id; |
| | 20 | }}} |
| | 21 | |
| | 22 | 3. Professor selects student and enters advising dates. |
| | 23 | |
| | 24 | 4. System inserts advising relationship: |
| | 25 | {{{ |
| | 26 | INSERT INTO Advice(Student_Id, Professor_Id, Start_Date, End_Date) |
| | 27 | VALUES (:student_id, :professor_id, CURRENT_DATE, :end_date); |
| | 28 | }}} |
| | 29 | |
| | 30 | 5. System confirms advisor assignment. |