CREATE TABLE TiberDM.ExamFact (
    id                  MEDIUMINT   NOT NULL AUTO_INCREMENT,
    SchoolDimId         MEDIUMINT   NOT NULL,
    AcademicYearDimId   MEDIUMINT   NOT NULL,
    ExamDimId           MEDIUMINT   NOT NULL,
    StudentDimId        MEDIUMINT   NOT NULL,
    percentCorrect      DECIMAL(10,2)   NOT NULL,
    examRank            INT             NOT NULL,
    examPoints          DECIMAL(10,2)   NOT NULL,
    assessmentName      Varchar(1024),
    assessmentId        INT
    PRIMARY KEY (id)
);

Create Unique Index ExamFact_Uidx01
On TiberDM.ExamFact (SchoolDimId, AcademicYearDimId, ExamDimId, StudentDimId);
;
