in reply to Keeping Order with mySQL (Mildly OT)

There are a few things that I can think of to do, that wouldn't involve much SQL.

The SQL Way:
Or you can do it the perl way Typically, I'd like to think that perl is better for sorting small to moderate result sets. For instance instead of doing a huge "select" with a parameter, and then sorting by a certain value, then doing the "order by" statement when you know that you're only going to get a few results, bite the bullet, get out of your sql (and whatever locks it might have) and do it quickly in perl.

Hope this helps.     --jay