>If the connection goes out of scope without being explicitly closed it will not be returned to the pool of available connections until the Dispose() is called - which, in turn, will not happen until the GC gets around to it - potentially quite a long time. (Actually that is a bit of an over-simplification - there are circumstances where it might be reclaimed but if those circumstances occur there's something wrong anyway)
>
>If you do open a connection explicitly (rather than, as Bonnie rightly suggests, relying on higher level objects to handle it implicitly) the safest option is:
Using sc As New SqlConnection(connectionString)
> sc.Open()
> 'Grab data
>End Using
>
which will guarantee that the connection is closed (and thus returned to the pool) when the block is exited. This will be true even if an exception is thrown within the block.
Thanks, I will check it out and provide a follow up on this.