Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP 9 tells me this is a bad index, I used it fine in VF
Message
 
 
To
24/05/2005 17:43:43
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows 2000 SP4
Network:
Novell 6.x
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01017297
Message ID:
01017309
Views:
19
>Can anyone explain why I get an error if I try to create this index in VFP9 when it ran fine in VFP8 and earlier????
>
>INDEX ON UPPER(SUBSTR(cg_lname,1,AT(" ",cg_lname))+cg_fname)+loan_acct TAG coname

You've variable lenghth index key here but VFP supports only fixed lenght index keys. VFP determines the lenght of the key based on the current record at the time when INDEX command is issued. After index is created, if new index key lenght exceed existing key lenght, VFP9 generates an error because of possible index key truncation. The previous VFP versions silently truncated such keys. To avoid such problems, the index key expression should always return fixed lenght value. The PADR function could help with that. See http://fox.wikis.com/wc.dll?Wiki~IndexExpressionRequirements~VFP for more info.
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform