Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Find out if index is filtered
Message
 
 
À
31/07/2001 07:20:58
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00537153
Message ID:
00538124
Vues:
12
>>>Hilmar.
>>
>>These two lines are probably the ones of interest for you...
>> m.ctagname = UPPER(TAG(lnTag))
>> m.ctagexp = UPPER(SYS(14, lnTag))
>
>Wayne,
>
>It seems to me there has been a confusion between the INDEX EXPRESSION and the FILTER EXPRESSION (for the index). I was asking for the FILTER EXPRESSION, which can be obtained through the function FOR() (I learned this in other replies to my question). I think you should add this to your sample code: it seems to me that you save index name and expression, but not the filter expression. I didn't test this, but I don't see any code to save the filter expression. Example: if I index with a command like: INDEX ON CLIENTCODE TAG CLCODE CANDIDATE FOR NOT DELETED(), I think the index name (CLCODE) and the expression (CLIENTCODE) would be maintained, but the filter (NOT DELETED()) would not.
>
>Hilmar.

Hi Hilmar,

Here is an example from one of my applications:
lnTagCount=TagCount()
if m.lnTagCount>0
     dimension laIndTags[m.lnTagCount], ;
          laIndExpr[m.lnTagCount], ;
          laFilterExpr [m.lnTagCount]

* -- NSL 5/31/00 Check for indexes deleted
     llChangeIndex=.f. && Reset to false
     lnCount=0
     do while m.lnCount<m.lnTagCount and oValid.lContinue
          lnCount=m.lnCount+1
          laIndTags[m.lnCount]=upper(tag(m.lnCount)) && TagName
          laIndExpr[m.lnCount]=upper(sys(14,m.lnCount)) && Index Expression
          laFilterExpr[m.lnCount]=upper(for(m.lnCount)) && Filter Expression
FWIW, in VFP7 there is a new function ATAGINFO (?), which places information about tags into array.
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform