Can't connect with database suddenly!

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • LostPuppy101
    New Member
    • Aug 2015
    • 2

    Can't connect with database suddenly!

    Godaddy updated their server recently and now we can't connect to our database.

    Here is the connection string: strDBPath="Driv er={MySQL ODBC 3.51 Driver};Server= name.db.number. hostedresource. com;DATABASE=db fname;UID=useri d;PWD=password; "

    I've double checked with Godaddy that the driver is correct, the connection string looks right, but no connection.

    Using MySql 5.5, IIs 7, windows server (long story)

    Error code below writes to page "empty" and "Operation is not allowed when the object is closed." You can see the test page here (constantly changing for testing reasons): http://www.oralbibleresources.com/sh...roblemCode.asp

    I'm NOT an expert in any of this so any of this, so really easy english will help. THANK YOU!!

    Code:
       response.write (connection)
    if connectionstring <> 0 then
      response.write (connectionstring)
    else
    	response.write "empty"  
    
    end if
    %>
                <%
    Set cnnSimple = Server.CreateObject("ADODB.Connection")
    cnnSimple.Open strDBPath & ";"
    Set rstSimple = cnnSimple.Execute("SELECT * FROM languages WHERE (languages.CD='YES') ORDER BY languages.language;")
    
    If Err.Number <> 0 Then
      
      Response.Write (Err.Description& "<br><br>")
       
      Response.Write("This means there is most likely a problem with the" & vbCrLf)
      Response.Write("""ConnectionString"" info that you specified.<br>" & vbCrLf)
      response.write (server.MapPath("nada"))
      Response.End
      
    End If
    On Error GoTo 0
    Last edited by Rabbit; Aug 20 '15, 07:39 PM. Reason: Please use [code] and [/code] tags when posting code or formatted data.
  • LostPuppy101
    New Member
    • Aug 2015
    • 2

    #2
    Problem solved, sorta. It was godaddy issue. We installed another database and imported everything to a Mysql 5.0 (rather than 5.5), which allows for direct access.

    Then we changed the connection string to the new hosting path and voila, it works.

    It’s a temporary fix as who knows when godaddy will stop supporting Mysql 5.0.

    Comment

    Working...