Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error building key for index
Message
 
 
To
24/06/2009 07:10:31
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01407965
Message ID:
01408029
Views:
68
This message has been marked as the solution to the initial question of the thread.
>Hi
>
>Help Please,
>
>I have the following index:
>
>
ALLTRIM(TTOC(sdatetime)+ALLTRIM(phone)+ALLTRIM(STR(id1))+ALLTRIM(STR(id2)))
>
>When I try to populate the table (alias), I get error message:"Error building key for index"

Don't use ALLTRIM for INDEXES and use TTOC(sdatetime,1) instead.

So, your index will be

TTOC(sdateTime,1) + phone + bintoc(id1) + bintoc(id2)

You would need to padr the values to their length when you construct your seek expression.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform