The scope of transactions does not impede code execution; it prevents a transaction. Thus, in the case of SqlCommand.ExecuteNonQuery , since it is inside the transaction, SqlCommand looks at the transaction coordinator and sees that it was called inside the transaction, so when it connects to SQL Server, the transaction is supported by SQL, so SQL writes data to the database but not readable unless the transaction is committed (or someone does a dirty read). If complete is never called, then when placing the TransactionScope it rolls back, and SQL can cancel the insert (or something else that it did).
Anything that uses transactions (such as other database technologies) must implement its .Net code to support transactions.
Transactions are essentially used in databases, but theoretically, other code can be used to support it.
But, to answer your question, the code does not stop before calling the Complete() method, it starts, but inside the transaction.
source share