SQL Connections

  • Thread starter Thread starter Laurent D.
  • Start date Start date
L

Laurent D.

Hi

After using a sql database, I want to detach it .
But some connection are still openned from the application.
My question:
How can I stop those connections ?
 
Hi,

1. Make sure that you close all connections within your app.
2. One or more connections are probably open until you close your app -
because of connection pooling.
You can't close them explicitly. They are closed when app closes. You can
set the number of pooled connections by modifying the connection string
Check .net help topic:
Connection Pooling for the .NET Framework Data Provider for SQL Server
 
In addition to what Miha said, if you want to do it server side, go into EM
and then select All Tasks, Detach Database. It will tell you how many open
connections you have. From there, you can select Clear, which will then ask
if you want to notify the users or not. Either way, it will clear all of
these connections.

Let me emphasize that this works as a technique, but it shouldn't be used in
place of closing connections and the like.it's a compliment rather than a
replacement.

HTH,

Bill
 
Back
Top