Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_databases thread: DB Connection in Beg ASP 2.0 Book


Message #1 by "James Crawford" <jim_crawford@a...> on Mon, 3 Feb 2003 22:05:01
IN Chapter 15 they have a complete Site to use and I am curious because as 
I see it the use of an "include" file on an ASP page (Checklogin.asp) will 
open another db conn each time that page gets used.  It can get used more 
than once if incorrect login is entered. Before redirect back to Login.asp 
should the db conn be closed?
I am new at this so maybe I am missing something 
Message #2 by "Philhouse" <spam@t...> on Tue, 4 Feb 2003 06:21:56
If memory serves, the server will clean up connections like that.

Hope that clears up confusion.

Clear Skies


> IN Chapter 15 they have a complete Site to use and I am curious because 
as 
I>  see it the use of an "include" file on an ASP page (Checklogin.asp) 
will 
o> pen another db conn each time that page gets used.  It can get used 
more 
t> han once if incorrect login is entered. Before redirect back to 
Login.asp 
s> hould the db conn be closed?
I>  am new at this so maybe I am missing something 
Message #3 by "James Crawford" <jim_crawford@a...> on Wed, 5 Feb 2003 04:02:14
Well I figured it out!!!   It is in the inc file there is no DSN= in front 
of the database  Which was kinda weird that it worked sometimes with 
db.Open "Classified" The Web Server is IIS on Win2000
I am putting db.close in the pages that use it too


> IN Chapter 15 they have a complete Site to use and I am curious because 
as 
I>  see it the use of an "include" file on an ASP page (Checklogin.asp) 
will 
o> pen another db conn each time that page gets used.  It can get used 
more 
t> han once if incorrect login is entered. Before redirect back to 
Login.asp 
s> hould the db conn be closed?
I>  am new at this so maybe I am missing something 

  Return to Index