Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Ascending w/Descending in same index?
Message
De
06/01/2000 22:46:44
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00314175
Message ID:
00314292
Vues:
20
>Hi,
>I need to be able to create an index with 2 fields where the first column is ascending and the second column is descending. They are both character fields. This is how the data looks:
>
>Ts# Pr#
>------------ ----------
>98-10017-A 108155
>98-10016-A 106997
>98-10015-A 107070
>98-10013-A 105211
>98-10010-A 105210
>98-1001-E 118757
>98-1001 CB 114641
>98-1001 125183
>98-1001 121756
>98-1001 109035
>
>I am using the follwing index expression:
>UPPER(ts_number)+LTRIM(STR(pr_number,8,0)) DESCENDING
>
>However, I really need it to be ascending on the first column, descending on the second within this same index. Any ideas?
>
>I have no idea how to post in fixed width so I apologize for the formatting of the data above. TS# is actually 30 characters long.
>
>Thanks in advance.

UPPER(ts_number)+bintoc(-pr_number)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform