I have a number of rows in a selection with a sort index like
ID text date sort_index
43 ABC 2013-05-28 3
93 DEF 2013-05-28 14
12 ABC 2013-05-28 103
[...]
Now I would like to renumber the sort_index
from 0 to 2. The group element is date
.
How can I do that by using MySQL?