Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Wild card in where clause
Message
De
27/07/1999 20:33:43
 
 
À
27/07/1999 20:10:54
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00246921
Message ID:
00246964
Vues:
24
>>Also what would work for a logical field? I have a form property with a nValue of 0, 1 or 2 and I want to select on obsolete = .t., .f. or either.
>>

Assuming that 0 = .T., 1 = .F. and 2 were either, you could write a nested IIF() statement like:

IIF(nValue = 2, .t., IIF(nValue = 1, ! obsolete, obsolute))

but it's ugly and not portable. You might consider building the SQL SELECT statement in a string and executing it via macro expansion instead, which could embed the correct condition(s) in the WHERE clause based on your form values.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform