Change the row position of a record without messing anything else MySQL?
1
vote
1
answer
3176
views
Hi I would like to ask if there is a smart way to change the record position of a table in mysql. My problem is this: I have a table with statistics data and when I recover all the details in a table called "details" I get the following result:
id | name
1 | Residents
2 | In age from 0 to 6
3 | In age from 6 to 14
4 | In age from 14 to 30
5 | In age from 30 to 66
6 | Total school population
7 | Students in kindergarten
8 | Students in high school
9 | ...
10 | ...
11 | 66 years and over
I would like the 11th record to be right after the 5th, thus right after "In age from 30 to 66". Is there a smart way to do that?
Thanks!
Asked by user3019105
(125 rep)
Mar 15, 2014, 10:40 AM
Last activity: Mar 15, 2014, 11:22 AM
Last activity: Mar 15, 2014, 11:22 AM