Long lists of hosts with numerical parts sort (according to SQL "ORDER BY") in this counter-intuitive way:
A few hundred lines sorted in this manner is annoying to say the least.
I suggest sorting lines with something like strnatcasecmp() (http://php.net/manual/en/function.strnatcasecmp.php) to make navigation in long lists more consistent.
AFAIK there is no equivalent of strnatcmp() in MySQL 5 (?) so it would probably have to be done in PHP after retreiving the data. On the other hand, ORDER BY could be removed from the SQL query.
/Johan
Code:
host1 host11 host12 host2 host21 host3
I suggest sorting lines with something like strnatcasecmp() (http://php.net/manual/en/function.strnatcasecmp.php) to make navigation in long lists more consistent.
AFAIK there is no equivalent of strnatcmp() in MySQL 5 (?) so it would probably have to be done in PHP after retreiving the data. On the other hand, ORDER BY could be removed from the SQL query.
/Johan