Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Using option button in sql
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Database:
MS SQL Server
Divers
Thread ID:
01311140
Message ID:
01311206
Vues:
33
>How will add with my query.
>SELECT scode,CODE,descr,fname,descru,fnameu,lcode,sec,sex,rtel FROM student WHERE admtd=1;
>aND lcode>=thisform.lcodefm.value AND lcode<=thisform.lcodeto.value...
It is always better to not use thisform properties in the query.

Use separate variables outside of the query, e.g.

lcMinCode = thisform.lCodeFm.value
lcMaxCode = thisform.lcCodeFm.value

select ... where lCode between m.lcMinCode and m.lcMaxCode ...
If it's not broken, fix it until it is.


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

Click here to load this message in the networking platform