sid total student_number rank 1 100 99 1 2 100 90 2 3 100 90 2 4 100 70 3 .... I want to obtained rank and update student ranks in my table