Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Cursoradapter keeps the lettercase
Message
From
27/09/2005 06:47:24
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Database:
MySQL
Miscellaneous
Thread ID:
01053310
Message ID:
01053353
Views:
14
David,

>Is there a way to make the cursoradapter to keep the case of the table name when generating the update statement? It seems to turn the table name into all lowercase.

You can interrupt the process just before the update is sent by putting code into the .BeforeUpdate event method to modify the statement that will be sent (it's in the cUpdateInsertCmd incoming parameter, which you can change as you like). Note that the cDeleteCmd listed as a parameter is just used if you have specified .UpdateType = 2 (delete followed by insert).

For Inserts or Deletions, you can trap the commands in the .BeforeInsert and .BeforeDelete methods (parameters are cInsertCmd and cDeleteCmd).

You could use a STRTRAN for each subclass of CA to patch up the table name for that subclass, or you could do a generic version that looks at values in the .Tables property and uses it/them to create STRTRAN statement(s) to change the SQL command before it is executed.
David Stevenson, MCSD, 2-time VFP MVP / St. Petersburg, FL USA / david@topstrategies.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform