Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Send Variables to a sql view
Message
De
15/04/2004 18:34:54
Dragan Nedeljkovich
Now officially retired
Zrenjanin, Serbia
 
 
À
15/04/2004 18:22:44
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Divers
Thread ID:
00894597
Message ID:
00895379
Vues:
21
>I don't get the error but I don't get a record set returned either.
>adding a +?Morder seemes to simply make the last statement a query rather than make it a seperate query plus an order statement.
>mORDER = 'ORDER BY BRAND, CATEGORY, DESCRIPT '

That surely won't work. When creating a remote view, you're basically writing a select statement in the language of the remote server. VFP can help you by providing variables which will be substituted at runtime - but that doesn't include macros. Macros don't exist in the remote language, and VFP's parser won't expand them for you.

Anyway, you can always hardcode the default order into the view definition (i.e. put the Order By as a part of the view definition), and then once you actually open the view (NODATA doesn't matter), index it or just select from it into another cursor using any order you like.

SQLExec() won't raise an error, but it will return a -1 if there was an error, and you can issue an aError(aErrArray) to get the ODBC error message into aErrArray, which you can then inspect.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform