Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How i will retrive data based variable condition
Message
 
 
À
04/06/2005 07:44:36
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows 2000 SP4
Network:
Windows 2000 Server
Database:
MS SQL Server
Divers
Thread ID:
01020224
Message ID:
01020231
Vues:
15
>Hi Experts,
>
>I have an sql Query statement, i want retrive data based on condition like
>
>cCod = '1'
>cBranch = 'Brn1'
>
>IF Thisform.Check1.Value = 1
> cCondition = 'ItmMast.ItemCod = cCod'
>Else
> cCondition = 'ItmMast.ItemBrn = cBranch'
>Endif
>
>'Select ItmCod, ItmDes From ItmMast Where cCondition'
>
>How i will i convert this to an Sql Server statement.
lcSQL = 'Select ItmCod, ItmDes From ItmMast Where' + cCondition
SQLExec( ...., lcSQL )
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform