Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Passing Arbitrary Conditions to Parameterised Views
Message
De
22/03/2004 01:33:05
Dorin Vasilescu
ALL Trans Romania
Arad, Roumanie
 
 
À
21/03/2004 07:53:34
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00888275
Message ID:
00888421
Vues:
13
Hi
I remember something about using macrosubstitution instead parameters.
SELECT Contacts.*;
 FROM ;
     CONTACT!CONTACTS;
 WHERE &qrycode
The qrycode variable must exists at design times, otherwise wil be includes as is, and the SQL command will fail.




>Whats the trick for creating a parameterised view with arbitrary filter conditions (held - eg - in a string variable called "qrycode") ?
>
>I've tried
>
>SELECT Contacts.*;
> FROM ;
> CONTACT!CONTACTS;
> WHERE (?qrycode)
>
>which crashes either with "function name missing" or "invalid sql clause"
>
>and
>
>WHERE EVALUATE(?qrycode)
>
>which doesn't crash, but never finds any records, even when I set "qrycode" for known matches.
>
>The idea is to allow users to create their own queries as parameterised views on whatever fields and conditions suit them at the time.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform