>For those who don't recall, EBCDIC is the ancient char system that orders like this in a natural ascending string sort:
>
>1) lower alpha
>2) upper alpha
>3) digits
>
>Quite the opposite of ASCII. Anyone think of a way to simulate this sort with a vfp index, on a field with mixed alphanumeric as below? These strings are varying in length, and I really want a structural index for this, not SQL or looping techniques involving code. I may be barking up the "impossible tree" here, but sometimes a fresh perspective can see some idea someone else has missed...
>
>For example, given this sequence:
>
>12G5A77
>123C6H
>12AB5
>123C6h
>
>I want to get:
>
>12AB5
>12G5A77
>123C6h
>123C6H
I seem to remember something like sys(15), which actually needs a 256-character string and performs an equivalent of chrtran() on your key, but we did use that to achieve our national collationg sequence back in foxplus days. The only trouble is 1) you have to build this translation string, and 2) it needs to be in memory whenever you try to open the table using such a key.
If that's OK with you, index on sys(15,your_field, your_tran_string) tag yadayada, or something like that.