Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Order by
Message
From
06/12/2005 12:22:41
 
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01075391
Message ID:
01075399
Views:
30
>I try to use,
>in sql order by thisform.order.vlaue
>but now working, how can be

I always am careful not to use thisform or this in a SQL query. I would usually dump that in a variable and make reference to it such as ORDER BY &lcOrder.

Or, if you use SQLExec(), you can have something like this:
IF NOT goSQLExec.SQLExec('SELECT Table.Numero,Table.ID FROM Table WHERE Table.Table="'+ThisForm.cTable+'"')
   RETURN .F.
ENDIF
By that, no matter if the SQLExec() is executed within or not the scope of the form or the this, it will always work.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Reply
Map
View

Click here to load this message in the networking platform