fixed teacher db insert issue