|
Basic error in numerical sorting of album names
|
|
13-01-2014, 11:48
(This post was last modified: 13-01-2014 11:49 by simoncn.)
Post: #27
|
|||
|
|||
RE: Basic error in numerical sorting of album names
(13-01-2014 08:55)simoncn Wrote: Thanks for this helpful summary of the issues involved. I'd like to add a few points: Another requirement that needs to be added is 5) The ability for the user to override numeric sorting for individual items where the number recognition algorithm would produce a sort order that isn't what the user wants. This isn't as straightforward as it sounds. The user would expect to be able to do this override by adding an ALBUMSORT tag with the value of this tag being used to do an alphabetical comparison. The problem is that it isn't possible to mix numeric and alphabetic comparisons without violating the total ordering contract of the comparison operation: if a is less than b and b is less than c, then a must also be less than c. To preserve total ordering, it would be necessary to either do numeric parsing of the ALBUMSORT value (which defeats the purpose of the manual override) or convert the parsed numeric values of all other items into equivalent sortable alphabetic values where the numbers are padded with some predetermined number of leading zeros (so 7 might become 00007 and 456 might become 00456). I don't think either of these approaches would be satisfactory. |
|||
|
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)

Search
Member List
Calendar
Help



