Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Need help with INDEX COMMAND
Message
 
 
À
05/07/2004 14:19:16
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00920784
Message ID:
00920789
Vues:
19
Hi Alvison,

There're different kind of indexes in FoxPro and command you use to make one current would depends on which kind you're referencing. It's better to use the structural compound indexes. They're stored in a structural compound index file always has the same base name as the table and is automatically opened when the table is opened. For example,
* Create structural indexes
USE mytable EXCLUSIVE
INDEX ON field1 TAG field1
INDEX ON field2 TAG field2
...
INDEX ON field1+field2 TAG f12
...
USE

* Open table with order set 
*   may be slower than opening a table and setting order afterwards
USE mytable ORDER TAG f12
...
* Set order to another tag
SET ORDER TO TAG field1
...
* Set order using tag name stored in a variable - Name expression
lcTagName = "field2"
SET ORDER TO TAG (lcTagName)
>I am Newbie to Fox, I am teaching myself this, I am using DB with FPDOS26 and when it comes to Index, I go like SET INDEX TO varNAme but I get an error saying DB not INDEXED! what I am doing wrong friends?
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform