Cgeo: Natural sort by geocode

Created on 9 Feb 2017  路  5Comments  路  Source: cgeo/cgeo

Detailed steps causing the problem:
  • Open list of caches
  • Sort by geocode
Actual behavior after performing these steps:

Caches are sorted lexicographically/alphabetically.

GC2345
GC56EFG
GC77
Expected behavior after performing these steps:

Natural sorting, for example:

GC2345
GC1ABCD
GC56EFG

Most helpful comment

Sure, but that is boring ;)

All 5 comments

Interesting issue. We would need to calculate the Base 31 code to an integer and sort by this.

Wouldn't be easier if you sort by lenght and then alphabetically?

Sure, but that is boring ;)

BTW: You get the same result even without the change by just selecting sorting by age (assuming you are not mixing different websites).

Sorting by age may be misleading. People grab a cache GCcode, then take their time to prepare for publication. Have seen 1 yr delay myself.
Cache id (as used in gpx export) is what to look for.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

SirJ-Oz picture SirJ-Oz  路  7Comments

wolverine007 picture wolverine007  路  3Comments

Lineflyer picture Lineflyer  路  7Comments

smico picture smico  路  7Comments

Lineflyer picture Lineflyer  路  8Comments