Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Executing a SQL select statement
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00107813
Message ID:
00108057
Vues:
40
David --

I did not know this...thanks for the tip!

I am presently developing a simple, query-like mechanism for one of my apps. It takes user-specified parameters and constructs a SQL SELECT statement. Like Mat, I was jamming the whole statement (including "SELECT") into a memvar and firing it with "&". So far, it seems to work OK, but I have not yet created and run the .EXE version. I probably would have agonized for days trying to solve this, so I reckon that you just saved me (and probably Mat, too) a lot of time.

Thanks again -- Bill


>Mat,
>
>Just to add a little to the other replies, you are better off just building the phrases as strings and issuing:
>
>lcSQL = "from table..."
>SELECT &lcSQL
>
>instead of
>
>lcSQL = "select ..."
>&lcSQL
>
>If it should happen that you don't have any other SELECT statements in your code an .exe can fail with a "Feature Not Available" error because VFP wouldn't include the necessary support for the SELECT command since it didn't find any SELECT statements during the compile.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform