Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>You need to enable network DTC access as described in this <a href="http://technet.microsoft.com/en-us/library/cc753510.aspx" rel="noreferrer">Microsoft TechNet Article</a>. This change may have to be made on both the database and application servers. Often times DTC is already turned on a database server so I'd look at the application server first.</p> <p>Here is a screen shot of what we use except for the "Allow Remote Administration" option: <img src="https://i.stack.imgur.com/8YOq7.png" alt="Security Configuration Screenshot"></p> <p>I have not run into the HRESULT E_Fail issue you are now having but this article on <a href="http://blogs.msdn.com/florinlazar/archive/2004/06/18/159127.aspx" rel="noreferrer">XP SP2 and transactions</a> had this interesting suggestion:</p> <blockquote> <p>Another configuration setting that you need to be aware (although I consider it to be an uncommon scenario) is RestrictRemoteClients registry key. If the value of this key is set to 2 (RPC_RESTRICT_REMOTE_CLIENT_HIGH) then MSDTC network transactions will not be able to work properly. MSDTC supports only RPC_RESTRICT_REMOTE_CLIENT_NONE (0) and RPC_RESTRICT_REMOTE_CLIENT_DEFAULT (1) values. See <a href="http://www.microsoft.com/technet/prodtechnol/winxppro/maintain/sp2netwk.mspx#XSLTsection128121120120" rel="noreferrer">http://www.microsoft.com/technet/prodtechnol/winxppro/maintain/sp2netwk.mspx#XSLTsection128121120120</a> for more info on RestrictRemoteClients.</p> </blockquote> <p>Finally, while not specific to your issue a very important thing to note about using the <code>TransactionScope</code> class is that its default setting is to utilize a <a href="http://en.wikipedia.org/wiki/Isolation_%28database_systems%29#Serializable" rel="noreferrer">Transaction Isolation Level of Serializable</a>. Serializable is the most restrictive of the isolation levels and frankly its surprising that it was chosen as the default. If you do not need this level of locking I would highly recommend setting the isolation level to a less restrictive option (ReadCommitted) when instantiating a <code>TransactionScope</code>:</p> <pre><code>var scopeOptions = new TransactionOptions(); scopeOptions.IsolationLevel = System.Transactions.IsolationLevel.ReadCommitted; scopeOptions.Timeout = TimeSpan.MaxValue; using (var scope = new TransactionScope(TransactionScopeOption.Required, scopeOptions)) { // your code here } </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload