Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP8 OleDb driver and Transactions
Message
From
16/05/2004 17:20:47
 
 
To
16/05/2004 16:09:51
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00904450
Message ID:
00904458
Views:
18
I figured that was the problem. I thought maybe I could ADD the tables to the DBF, do the Transaction stuff, then REMOVE them. I tried issuing "ADD TABLE c:\blah\blah\blah.dbf" commands through the OleDbCommand object in ADO.NET, but I just get an exception "One or more errors have occurred processing the command.". So maybe the VFP8 OleDb driver doesn't support ADD TABLE or REMOVE TABLE.

The solution I ended up using was when the Transaction begins, make backup copies of the DBFs. If the Transaction is rolled back, restore the DBFs from the backups. If the Transaction is committed, delete the backups. It works. I have multiple INSERTS and UPDATES to SQL Server tables and VFP free tables, and if anything goes wrong I can rollback the changes to both now with no problem.

-----
Lee Perkins

>Transactions are not supported on free tables.
>
>
>>Does the VFP8 OleDb Driver support transactions? I'm doing UPDATEs and INSERTs against several free DBFs in VB.NET using the VFP8 OleDb driver. I'm using a System.Data.OleDb.OleDbTransaction object to wrap several UPDATEs and INSERTS in a transaction. If I roll the transaction back in the middle, the UPDATEs and INSERTS done so far are actually comitted. They don't get rolled back.
>>
>>Could I be doing something wrong, or does the VFP8 OleDb Driver just not support transactions (or at least not for free DBFs)?
>>
>>-----
>>Lee Perkins
-----
Lee Perkins
TigerBase Technologies

"Lee is one that would plug his brain into the internet, if he could, and STILL scream for more" - Very good friend of Lee's
Previous
Reply
Map
View

Click here to load this message in the networking platform