Search Posts

Author: Ajith Simha

MYSQL trigger for Cascading Delete : Workaround needed

Consider 3 Tables – Student(Id INT NOT NULL PRIMARY KEY, Name VARCHAR(100)); Test(Id INT NOT NULL PRIMARY KEY, Name VARCHAR(50), MaxMarks INT, TestDate DATETIME); StudentTakesTest(TestId INT NOT NULL REFERENCES Test(Id), StudentId INT NOT NULL REFERENCES Student(Id), MarksObtained FLOAT, MarksObtainedInPercentage FLOAT); Every time a student takes test, the average of all the tests taken by a particular student is stored in an index table. I am doing this with the help of triggers. I have applied […]