Results 1 to 2 of 2

Thread: Connecting to a database with UltraDev

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Oct 1999
    Location
    East Ballina,NSW,Australia
    Posts
    121

    Question Connecting to a database with UltraDev

    Hi All,

    I'm having a little trouble connecting to a database in ultra dev with a DNSless connection.

    My webhost in its FAQ section says that this is how I should connect to the DB..
    <code>
    <%Dim Conn, RS
    Set Conn = Server.CreateObject("ADODB.Connection")
    Set RS = Server.CreateObject("ADODB.Recordset")
    DSNName = "DRIVER=Microsoft Access Driver (*.mdb);DBQ="
    DSNName = DSNName & Server.MapPath("/USERNAME/database/mydatabase.mdb")
    Conn.Open DSNName
    sql = "SELECT * FROM [TableName] WHERE (((TableName.FieldName)='Value'))"
    RS.Open sql, Conn, 3, 3%>
    </code>

    I have tried using this code in my connection string in UltraDev but it won't work. (note I have also made the changes to the username and my database name, and iam using an access DB).

    Does anybody know what possibly could be wrong, any suggestions would be greatly appreciated.

    Regards,

    Smithy.

  2. #2
    Fanatic Member chrismitchell's Avatar
    Join Date
    Jan 2001
    Location
    With Hobbes in New Zealand
    Posts
    568
    Do you have IIS set up on your machine?

Posting Permissions

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



Click Here to Expand Forum to Full Width