Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQLCommit() vs sending COMMIT via SPT
Message
From
10/11/2010 06:12:27
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
10/11/2010 04:10:08
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MySQL
Application:
Desktop
Miscellaneous
Thread ID:
01488689
Message ID:
01488707
Views:
41
>Dragan,
>
>Using SQL 2005 Express I've found that SqlCommit() doesn't decrease the @@trancount on SQL side, it stays 1 forever, which leaves me unsure of its success. So I gave it up and went to sqlexec(h, "commit transaction").
>
>Am I right in saying that SQLCOMMIT() is a "generic way" of sending the COMMIT command? If one uses SPT, "COMMIT"ing may have different syntaxes with different backend databases - (like in MySQL the command is just COMMIT)?

I'd guess that, since all fox's sql functions communicate with the ODBC driver, that it just tells the driver to send an appropriate command... As with any intermediary, you can't always be sure that it will do everything. You can check what it does if you have some trace utility or extensive logging on the server side. Haven't tried that on MySql yet, nor did I try the profiler on SQL. Busy with other stuff and setting up a test would require going to another machine and too much time.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform