title: Is it safe to retry a command/connection timeout?
body: <p>We've been using a mechanism (a class called <code>SqlDeadlockHelper</code>) for quite a while now, and it has helped us quite a bit when trying failed database calls due to a deadlock. <code>SqlDeadlockHelper</code> will catch a <code>SqlException</code>, recognize that it's a deadlock, and try again. The second attempt almost always succeeds.</p>
  
  <p>Is it safe to do something like this for command and/or connection timeouts? I mean, it's not possible for work to complete on SQL Server, only to timeout before the data gets back to the caller, is it?</p>
  
  <p><strong>Edit:</strong></p>
  
  <p>Transactions have been mentioned as a way to treat calls as a unit of work. That way it can succeed or rollback entirely. But what about a single ADO.NET call that only does one thing. Is it necessary to wrap that in a transaction?</p>