When to Close the Connection?

F

Frank Dulk

I developed a system in VB with Sql Server 2000
using ADO, everything this is really very satisfied with the acting of the
sql server, does mine doubt the following it is, because I see many comments
on the subject... do I possess a global variable in I modulate has the
connection with the bank.... when do I open the system I carry the bank and
only bolt in the exit... is that correct? if I use MSDE would not have q to
close the connection to use with more simultaneous users? doesn't have as
leaving the inactive connection? should I open and to close in each
transaction with the bank?
 
D

David Gugick

Frank said:
I developed a system in VB with Sql Server 2000
using ADO, everything this is really very satisfied with the acting
of the sql server, does mine doubt the following it is, because I see
many comments on the subject... do I possess a global variable in I
modulate has the connection with the bank.... when do I open the
system I carry the bank and only bolt in the exit... is that correct?
if I use MSDE would not have q to close the connection to use with
more simultaneous users? doesn't have as leaving the inactive
connection? should I open and to close in each transaction with the
bank?

Leaving a connection "connected" does use some small amount of memory on
the server, but it doesn't really make a difference if the connection is
inactive. That is, if you are using MSDE which cannot operate
efficiently with more than 5(?) active queries, it won't matter if you
have 20 connections as long as only 5 or fewer queries are running.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top