Windows will not sort with numerical values (such as inventory window (Qty/Bulk) or character sheet skills (Current/Base)
Nothing with a numerical value will sort correctly. It always sorts by the items' name FIRST and then the numerical value. It should be sorted by numerical value first then the name as secondary.
ie I open my Inventory window with these items in it:
50 FIre beetle carapace
10 FLame beetle CAraspace
30 FLame beetle COmpound Eye
Let say I click the bar of Qty to sort by Qty. It will then show this:
50 Fire Beetle Caraspace
10 Flame Beetle Carapace
30 Flame Beetle Compound Eye
When clicking the Qty bar, the sort FAILED. It chose to sort by name first, and then sort by Qty. Thats wrong.
If I click the bar, above Qty, to sort by Qty, this list SHOULD be sorted as follows:
10 Flame Beetle Carapace
30 Flame Beetle Compound Eye
50 Fire Beetle Caraspace
10 is the lowest qty and 50 is the highest.
This problem is also is existent for most any kind of searches. Lets say you open your Character Sheet, then click the Skills tab. The only two numerical values I can sort by is Current or Base (skills).
If I click the bar above 'Current', I should expect the list to be sorting Current values from 1 to 1000 (or whatever the max is). But instead the numeric values are all 'random'. Well not really. Its not random. Its sorting everything by name first, then its sorting the 'Current' values within the initial Name sorting.
I'm not sure how your game queries the database, but this is what it is doing:
It will sort by name FIRST, IGNORING all references to QTY (or any numeric values) until the name sorting occurs first.
Solution: IF you are using a SQL statement.
You should remove all references to sort (ORDER BY statement) during the initial query.
Example:
If Request("sort") <> "" Then (Note: "" meaning blank/no sort was selected)
query = query & " Order BY " & Request("sort") & ",NAME" (Note: dont use 'Order By Name, " & Request("sort") )
Else
query = query & "Order by NAME" (Sorting by Name should be used if the user did not click a bar to sort something)
End If
Hope this makes sense and you understand what I'm talking about ^-^
After looking down in forums, I THINK this is what Knossos is talking about below. Anything with numeric values will never be sorted as a primary field. The fields he is refering to is all numeric.
Has nothing to do with the database sorting actually. Its waiting on an updated client to fix the sorting.