Does SqlDataAdapter closes the SqlConnection automatically?


One reader asked me that when using the SqlDataAdapter with SqlConnection why don't I explicitly close the connection. The reason is that the connection is closed automatically by the SqlDataAdapter. A simple test you can do is to check the connection state after filling the DataSet with SqlDataAdapter. You will find that the connection was closed.