Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Integer indexing doesn't fly so well
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Database:
Visual FoxPro
Divers
Thread ID:
01470116
Message ID:
01470133
Vues:
55
What are the types of the fields? If the fields are integer, you can use BINTOC function.

>Well, I have approached this from several vantage points to get the line item numbers
>in numeric order, but they do not come out okay when I make my index as follows:
>
>
>INDEX on PADL(ALLTRIM(STR(groupid)), "") + PADL(ALLTRIM(STR(quoteid)), 4, " ") + ;
>   PADL(ALLTRIM(STR(lineitem)), 4, " ") TAG gqteline
>
>
>Example: The numbers for the column called LineItem just don't go into any order.
>I even padded spaces in, but that didn't fix it.
>
>
>GROUPID  QUOTEID  LINEITEM
>1               1               2
>1               2               1
>
>
>How do I get the numbers to come out like this in the index expression?
>
>GROUPID  QUOTEID  LINEITEM
>1               2               1
>1               1               2
>
>
>Maybe I need to leave out the QuoteID? I'll try that.
>
>Cecil answering Cecil's question: "Yes, that works just fine, Cecil. Good job!" See below:
>
>INDEX on groupid + lineitem TAG grpqteline
>
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform