changed classId to classCode - refactored
updated the database design