I\'ve had a suspicion that a database connection used in one of our applications is not always closed. I went to see the code and I\'ve found a class DataProvider
conn.Dispose(); will also close the connection, so can't hurt changing it to follow the dispose pattern.
But there functionally equivalent so there must be a problem else where.
http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqlconnection.close.aspx
If the SqlConnection goes out of scope, it won't be closed. Therefore, you must explicitly close the connection by calling Close or Dispose. Close and Dispose are functionally equivalent. If the connection pooling value Pooling is set to true or yes, the underlying connection is returned back to the connection pool. On the other hand, if Pooling is set to false or no, the underlying connection to the server is closed.