Need to clear your connection pool? You can with .NET 2.0.

If you need to clear your connection pool in a .NET application, with the .NET 2.0 Whidbey framework, you will have the option of clearing the pool.  ADO.NET 2.0 provides two static methods for doing this.

  • SqlConnection.ClearPool( SqlConnectionObject ).
  • SqlConnection.ClearAllPools().

According to what I have read, this feature will be available in the .NET 2.0 Sql Server and Oracle Clients from Microsoft.

Enjoy,
Wally

3 Comments

  • Any chance this could be implemented on IDbConnection? I rarely use the specific classes, as I don't want to force my users/coworkers to use a single database engine.

  • i wondering to know what happend with the current connection that still connected when i clear all pool.

  • how do you use connection pooling in asp,i want to handle connection poooling in asp not in asp.net.
    pls help !!!!!!!!!

Comments have been disabled for this content.