Good afternoon, here I am faced with a task that is simple in appearance, but for the solution of which you need to keep your brains going :)
So: we have the following table:
id
rating
place
one
86
Null
2
five
Null
3
five
Null
four
41
Null
five
one
Null
6
91
Null
It is necessary to place a place (place) in the rating of each record, based on points (rating), and if the points are the same, use the secondary sign (id in this case). As a result, you need to get the following table: ')
id
rating
place
one
86
five
2
five
2
3
five
3
four
41
four
five
one
one
6
91
6
Important note: the answer should be one UPDATE query (you can use nested SELECT queries).