Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Strange Index Error
Message
From
18/04/2013 14:10:57
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01571265
Message ID:
01571393
Views:
57
>If there is a potential of returning different values, this function should not be used.
>I think VFP Help can be a bit more explicit here. I am using community supported VFP
>help, so I suggest to update this topic with more information as why this function
>should never be used for indexing without second parameter.

There could be use. If you're not looking for a sorted order, per se, but rather just the ability to find a particular entry on a particular date, it would work. In that case it's just a key.

>BTW, it doesn't make sense to use DTOC as is anyway, because the rows will not be properly sorted.

Also, if you use the form:
SET DATE YMD
SET CENTURY ON
INDEX ON DTOC(dMyDate)...
and it will create a properly sorted index. Each time you go to update though ... beware.

This problem of Tommy's actually exposes a flaw in the xbase index design in that it doesn't convey that meta data about the environment from which it was created. I'll have to address that in Visual FreePro and remove this shortcoming.

I'm still not understanding the cause of Tommy's error outside of a bonafide bug in VFP9SP1.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform