Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SET KEY and BINTOC()
Message
From
02/09/2006 18:13:57
 
 
To
02/09/2006 17:36:50
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01150560
Message ID:
01150565
Views:
34
>Is there a trick to use SET KEY command when the index expression contains BINTOC() ?
>
>I've created an index based on 2 integer fields:
>BINTOC(INT1) + BINTOC(INT2)
>
>I want to use the SET KEY to see only some fields that match the 1st value
>
>I'm trying this way with no success:
>
>
SET EXACT ON
>SET ORDER TO indicenovo
>SET KEY TO BINTOC(lnValue)
>
SET EXACT OFF
SET ORDER TO indicenovo
SET KEY TO BINTOC(lnValue)
>where lnValue is an Integer
>
>But if I create an index using PADL instead of BINTOC it works perfectly:
>PADL(int1,6,"0") + PADL(int2,6,"0")
>

ARE YOU SURE ?

>What am I doing wrong ? I'd prefer to use BINTOC() because this way I can reduce the index file size...
>
>TIA
>
>Cesar
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform