Best way to change order of rows in MySQL table?
问题 I have a MySQL table with rows that need to be sorted in a particular order decided by the user. In other words, need the user to be able to insert a new row at a random point in the table, and also move existing rows to a new random location/row number in the table output on a select query... Solutions I have thought of so far: I could use an integer with an ORDER BY, however, then i will need to update every row after the point of "insertion". I could use a timestamp and an index integer,