Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to use BEGIN TRANSACTION with Sql Passthrough
Message
From
16/09/2004 08:05:28
Suhas Hegde
Dental Surgeon
Sirsi, India
 
 
To
16/09/2004 07:23:15
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00942755
Message ID:
00942834
Views:
22
>
>Hi Fabio,
>Just curious
>
>Wouldnt this
>SQLEXEC(,'BEGIN TRAN;write command;COMMIT')>0
>be same as
>SQLEXEC(,'Insert ...')>0 since it executes in only one batch ?
>
>COuld U explain a bit ?
>
>Suhashegde
>

>
>If you can complete the transaction with a single batch
>( if the "write command" not required other feedback data from the client's application )
>then do it with a single batch.
>
>The
>SQLEXEC(,'BEGIN TRAN;write command;COMMIT')>0
>is like
>SQLEXEC(,'BEGIN TRAN')>0 AND SQLEXEC(,'write command')>0 AND SQLEXEC(,'COMMIT')>0
>but it is faster and the probability that it go ok is upper.
>
>If "write command" is a single T-SQL, then BEGIN TRAN;;COMMIT are implicit.
>
>Fabio

Would the above be usefull involving while updating bufferered changes ? I.e making a cursor updatable and then updating the cursor ?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform