Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Index Problems
Message
De
05/11/2000 22:03:03
Raymond Humphrys
Michigan Department of Community Health
Bath, Michigan, États-Unis
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00438192
Message ID:
00438200
Vues:
12
Rats!! I must be getting tired, that was it.

thanks a lot
>Hi Raymond,
>
>Suppose, you have FirstName Character 15 and LastName Character 25. You want to find your name:
>index expression FullName upper(FirstName+LastName)
>
>lcSearchName=upper(padr('Raymond,15)+padr(Humphrys,25))
>if seek(lcSearchName,'Employees', 'FullName')
>  =messagebox("Hooray! You're an employee!")
>else
>  =messagebox("Sorry... You're hired")
>endif
>
If you use alltrim, you will have an index or various length...
>Try to see Help on Indexes...
>
>>Why? What if the fields are different lengths?
>>
>>>>While building some compound indexes like the following ALLTR(A)+Alltr(B) name mytag, I found that I can not relate two tables together on the compound index. The table joins together just fine using the two indexes individually, but not when I concatenate them together. I went so far as to copy the concatenated values from one table to the next, reindexed and still the tables will not relate together correctly when the values are concatenated and a relation is set with the compound value.
>>>>
>>>>Anyone have a clue what I'm doing wrong?
>>>>
>>>
>>>In general, it's not a good idea to use Alltrim function in compound indexes. Use A+B or upper(A+B) as index expression, where A & B character fields.
>>>>thanks
Some days it's not worth chewing through the leather straps ...
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform