Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_databases thread: Problem opening MySQL database


Message #1 by "Pat Waddington" <paw@s...> on Sat, 27 May 2000 15:15:37 +0100
Dear all,



I have the following code in an ASP page:



<%



Response.Write "Define Connection" & "<BR>"



Set objConn =3D Server.CreateObject("ADODB.Connection")



Response.Write "Connection defined" & "<BR>"



Response.Write "Define Connection String" & "<BR>"



strConn =3D "Driver=3D{MySQL}; DATABASE=3DWEBDATA; UID=3Dsa; PWD=3Dpwd"



Response.Write "Connection String defined" & "<BR>"



Response.Write "Open Connection" & "<BR>"



objConn.Open strConn



Response.Write "Connection open" & "<BR>"



Response.Write "All done" & "<BR>"



objConn =3D Nothing



%>



The Response.Write commands are for tracing purposes.



When I try to run this in IE5 the page will not load properly because 

everything hangs up on the objConn.Open command. I have shown this is 

the case, because when the page times out the first five Response.Write 

lines are displayed (i.e. the last line displayed is 'Open Connection')



My OS is Windows 98; I use Frontpage 98; the ASP page is in 

c:\webshare\wwwroot\glicom\asp (executable folder) and the database is 

in the sane folder as the ASP page. I have to use a DSN-less connection 

because our hosting service does not support DSN (so they say).



Can anyone tell me what is happening and how I can get round the problem 

please?



Thank you



Pat Waddington




  Return to Index