Changes between Version 14 and Version 15 of P1


Ignore:
Timestamp:
06/25/26 10:56:15 (18 hours ago)
Author:
216009
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • P1

    v14 v15  
    9696
    9797=== '''Student_Subject'''
    98 This entity represents a specific student enrollment in a subject (course instance). It tracks grades, attendance, and status. It also acts as the central link resolving which professor teaches this specific instance to the student.
     98This entity represents a weak entity that depends on both Student and Subject. It tracks a specific student enrollment in a subject (course instance), including grades, attendance, and status, while resolving which professor teaches this specific instance.
    9999
    100 '''Candidate keys:''' ss_id (primary key).
     100'''Primary Key:''' Composite key consisting of (student_id, subject_id, ss_id).
     101
     102'''Discriminator (Partial Key):''' ss_id.
    101103
    102104'''Attributes:'''
    103105
    104 '''ss_id''' – serial (integer), required, unique (mapped to ss_id on the diagram)
     106'''ss_id''' – integer, required. Acts as the discriminator (partial key) for the weak entity. It uniquely identifies multiple enrollments of the same student in the same subject (e.g., if a student retakes a course).
    105107
    106 '''student_id''' – integer, required, foreign key to Student (on delete cascade)
     108'''student_id''' – integer, required, identifying foreign key to Student (on delete cascade). Part of the composite primary key.
    107109
    108 '''subject_id''' – integer, required, foreign key to Subject (on delete cascade)
     110'''subject_id''' – integer, required, identifying foreign key to Subject (on delete cascade). Part of the composite primary key.
    109111
    110 '''professor_id''' – integer, required, foreign key to Professor (on delete restrict) (materializes the assignTo relationship from the diagram)
     112'''professor_id''' – integer, required, regular foreign key to Professor (on delete restrict) (materializes the assignTo relationship from the diagram).
    111113
    112 '''enrollment_date''' – date, required, defaults to CURRENT_DATE (mapped to Enrollment_Date)
     114'''enrollment_date''' – date, required, defaults to CURRENT_DATE (mapped to Enrollment_Date).
    113115
    114 '''status''' – varchar(20), optional, defaults to 'Enrolled'
     116'''status''' – varchar(20), optional, defaults to 'Enrolled'.
    115117
    116 '''final_grade''' – integer, optional (mapped to Final_Grade)
     118'''final_grade''' – integer, optional (mapped to Final_Grade).
    117119
    118 '''absences_count''' – integer, optional, defaults to 0 (mapped to Abesense_Count on the diagram)
     120'''absences_count''' – integer, optional, defaults to 0 (mapped to Abesense_Count on the diagram).
     121
     122
    119123
    120124=== '''Advice'''