I'm trying to move an old site done with ASP & MySql from a provider to another.
On the new provider I have this problem. All the page that use a connection to the database after 20-30 seconds of inactivity raise the error "500 - Internal server error.There is a problem with the resource you are looking for, and it cannot be displayed."
To view again the page without errors I have to restart the browser.
For example if I open the test page (test.aspx):
<%
sql = "SELECT * from fam"
set rsFam = OggettoDB.execute(sql)
%>
<%do while not rsFam.eof%>
<a class="col" href="/7Cat.asp?IDF=<%=rsFam("Id_Fam")%>&Nome=<%=rsFam("Nome")%>"><%=rsFam("Nome")%></a> <br />
<%rsFam.movenext
loop
rsFam.close
%>
I can see the links of this page without problems and click them with success.
But If I click on a link or if I refresh the page after 20 seconds of inactivity I have the error "500 - Internal server error.."
I'm using this connection string on the file Global.asa:
ilclaudio
Member
6 Points
9 Posts
Problem with MySql connection after inactivity
Mar 01, 2012 09:10 PM|LINK
Hi all,
I'm trying to move an old site done with ASP & MySql from a provider to another.
On the new provider I have this problem. All the page that use a connection to the database after 20-30 seconds of inactivity raise the error "500 - Internal server error.There is a problem with the resource you are looking for, and it cannot be displayed."
To view again the page without errors I have to restart the browser.
For example if I open the test page (test.aspx):
<%
sql = "SELECT * from fam"
set rsFam = OggettoDB.execute(sql)
%>
<%do while not rsFam.eof%>
<a class="col" href="/7Cat.asp?IDF=<%=rsFam("Id_Fam")%>&Nome=<%=rsFam("Nome")%>"><%=rsFam("Nome")%></a> <br />
<%rsFam.movenext
loop
rsFam.close
%>
I can see the links of this page without problems and click them with success.
But If I click on a link or if I refresh the page after 20 seconds of inactivity I have the error "500 - Internal server error.."
I'm using this connection string on the file Global.asa:
'OggettoDB.Open "driver={MySQL ODBC 3.51 Driver};server=localhost;UIDmin;PWD=XXXX;database=XXXX"
Which is the problem according to you?
Thank you very much.
Claudio