closing database connection

Results 1 to 2 of 2

Thread: closing database connection

  1. #1
    Join Date
    Dec 1969

    Default closing database connection

    I&#039;m using a common database connection file with the dsn connection string and including it in other files requiring a database connection, i.e. &#060;!--#include File ="datalink.asp"--&#062;(for ease of changing the connection strings) which seems to work o.k. I am placing the following commands at the end of the VBScript in such files.<BR><BR>rs.close<BR>conntemp.close<BR>set rs=nothing<BR>set conntemp=nothing<BR><BR> Do these commands also need to be in the common database connection file or not (I would think this would just close the connection again before it is used)?<BR><BR>These seem to be alot of database connections being left open on my host server clogging it up (see my last post). I want to be sure It&#039;s not my files causing the problem before I start complaining to tech support!!

  2. #2
    Join Date
    Dec 1969

    Default Please don't

    start a new thread. The problem is probably on the host and not just your connection closing. Maybe you&#039;re on a server with someone&#039;s site that is getting hammered. Hard to tell. Start complaining to your host. That&#039;s where the problem is not in your code.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts