Use Microsoft Distributed Transaction Coordinator (ODBC)
Applies To: SQL Server 2016 Preview
To update two or more SQL Servers by using MS DTC
Connect to MS DTC by using the MS DTC OLE DtcGetTransactionManager function. For information about MS DTC, see Microsoft Distributed Transaction Coordinator.
Call SQL DriverConnect once for each Microsoft® SQL Server™ connection you want to establish.
Call the MS DTC OLE ITransactionDispenser::BeginTransaction function to begin an MS DTC transaction and obtain a Transaction object that represents the transaction.
Call SQLExecDirect once for each SQL Server you want to update.
Call the MS DTC OLE ITransaction::Commit function to commit the MS DTC transaction. The Transaction object is no longer valid.
To perform a series of MS DTC transactions, repeat Steps 3 through 6.
To release the reference to the Transaction object, call the MS DTC OLE ITransaction::Return function.
To use an ODBC connection with an MS DTC transaction, and then use the same connection with a local SQL Server transaction, call SQLSetConnectAttr with SQL_DTC_DONE.