Microsoft
Software
Hardware
Network
Question : TransactionScope - Sample Code
Hello Experts,
I have a need for a transaction, that will be able to span different tables on different databases. This led me to the TransactionScope class. From what I've read online, this should be able to get 'er done. But from the code samples I've found, I haven't been able to implement it. Can someone post a working sample code for this? Nothing complex, just the ability to insert a line into two tables on two different servers, and commit the transaction.
Psuedo Code:
'Start TransactionScope
'Do insert 1 for a table on Database Server 1
'Do insert 2 for a different table on Database Server 2
'Catch any errors
'Commit if successful - Rollback if failed
'End TransactionScope
Thanks!
Maurice
Answer : TransactionScope - Sample Code
Ive never really used TransactionScope. You could use 2 sepereate transaction and just roll them both back
Random Solutions
Inside Interface Problem Configuring PIX 515E
Get Current selected link - apply css
How do I update file, save to new location and keep original file as is using Visual Basic 2008?
ASP.net 3.5 vs 4
deal with crm 4 sdk with ASP
return double array in Delphi call to c++
New ESXi 4 Host (not responding) in vCenter
Exchange 2003 and 2010 coexistent - Outlook in 2010 cannot email to 2003
Install IIS with a vbs script.If supporting files needed pick from a predefined path.
Show Date time on webpage -coldfusion,jquery