Reputation: 32905
Would transaction work across multiple DB in the same SQL server?
If so, is this a Distributed transaction? or would basic BEGIN TRANSACTION
work?
Upvotes: 41
Views: 21198
Reputation: 2147
A transaction across multiple DBs in the same instance is a local transaction. BEGIN TRANSACTION will work just fine.
Upvotes: 57
Reputation: 95562
SQL Server documention is clear about how to start a distributed transaction.
Upvotes: -3
Reputation: 6352
Just tested it. BEGIN TRANSACTION
works as expected across two databases on the same server.
Upvotes: 13