Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Mar 2007
    Location
    Wikltshire UK
    Posts
    152
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Hi guys,

    Been mulling this one over for a couple of days, and still not closer to solution so any clues would be really usefull.

    I need to upload data to a an online (IE Http://www. address or IP) SQL7 Database, I've worked out the code for MySQL:

    Dim oConn As ADODB.Connection
    Sub ConnectDB()
    Set oConn = New ADODB.Connection
    oConn.Open "DRIVER={MySQL ODBC 5.1 Driver};" & _
    "SERVER=webaddress;" & _
    "DATABASE=DBname;" & _
    "USER=username;" & _
    "PASSWORD=pw;" & _
    "Option=3"

    StrSQL = ""
    Rs.Open StrSQL, oConn

    Set oConn = Nothing
    End Sub


    Which Works:

    Is there an equivalent (or do I need to change the Driver or something for SQL 7. Just dosn't seem to be any clear solutions out there for this.

    Gratitude in Anticipation

    Graeme

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts
    For example:

    oConn.Open "Driver={SQL Server};" & _
    "Server=webaddress;" & _
    "Address=webaddress,port;" & _
    "Network=dbmssocn;" & _
    "Database=DBname;" & _
    "Uid=username;" & _
    "Pwd=pw;"

    You must specify the IP address in the Server and Address parameters, and in the Address parameter it must be followed by the port number.

  3. #3
    2 Star Lounger
    Join Date
    Mar 2007
    Location
    Wikltshire UK
    Posts
    152
    Thanks
    2
    Thanked 0 Times in 0 Posts
    [quote name='HansV' post='789952' date='20-Aug-2009 15:35']For example:

    oConn.Open "Driver={SQL Server};" & _
    "Server=webaddress;" & _
    "Address=webaddress,port;" & _
    "Network=dbmssocn;" & _
    "Database=DBname;" & _
    "Uid=username;" & _
    "Pwd=pw;"

    You must specify the IP address in the Server and Address parameters, and in the Address parameter it must be followed by the port number.[/quote]

    Thank-You just the Clue I needed

    I'm still playing with this and Will get back to confirm solution works, once I've sorted it.

    Graliv

Posting Permissions

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