There are many circumstances where you will want to enforce a specific ordering for your database records. In our case, certain critics may request to be placed at the top of the list due to their seniority. The
JTable class has built-in functions that help you move records up and down within a list and add new ones in the correct place.
When we added the jos_critic table to the database, an ordering column was added. Because records are now added without values for this column, we need to go back and add this information now. For the record with id set to 1, change the ordering column to 1, and change ordering to 2 for record 2. If you are using the MySQL command line client, this query will do it automatically:
UPDATE jos_critic ...