[Building Sakai] How about a unique constraint GB_GRADE_RECORD_T

Joshua Swink joshua.swink at gmail.com
Wed Aug 7 14:42:28 PDT 2013


Would it make sense to add a unique constraint to the ID field of
GB_GRADE_RECORD_T?

Due to some missteps while we were setting up a QA server, we ended up with
duplicate IDs in our GB_GRADE_RECORD_T table. They were for entirely
different gradebook items. When we tried to change a student's score, we
saw a constraint violation of GB_GRADE_RECORD_T_U2, which is: UNIQUE
(GRADABLE_OBJECT_ID, STUDENT_ID). This was somewhat confusing and it took a
while to determine the cause.

I realize this is a rare occurrence, but if the ID field had a unique
constraint, there would have been a violation much earlier in this process
- and a much easier one to diagnose.

JIRA: https://jira.sakaiproject.org/browse/SAK-23844

Josh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20130807/804ea810/attachment.html 


More information about the sakai-dev mailing list