Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

connecting to mysql databse in asp (without dsn)

  • 19-12-2004 11:34AM
    #1
    Closed Accounts Posts: 5,284 ✭✭✭


    Trying to adapt the openwiki configuration asp script to work for me. What values should I be putting in for the driver and the server? Does anyone have any example code excerpts for doing this by any chance? Do I need the full pathname to the database file on the server?


Comments

  • Closed Accounts Posts: 5,284 ✭✭✭pwd


    here's the bit of the asp doc that I need to change. "this page cannot be displayed" is shown when I've tried all sorts of values in the string. (these are the default sample values below only)

    ' OPENWIKI_DB = "Driver={Microsoft Access Driver (*.mdb)};DBQ=e:\data\openwiki\OpenWiki.mdb"
    ' OPENWIKI_DB = "Driver={SQL Server};server=mymachine;uid=openwiki;pwd=openwiki;database=OpenWiki"
    ' OPENWIKI_DB = "Driver={Microsoft ODBC for Oracle};Server=OW;Uid=laurens;Pwd=aphex2twin;"
    ' OPENWIKI_DB = "MySystemDSName"
    OPENWIKI_DB = "MySQLOpenWiki"
    ' OPENWIKI_DB = "PostgreSQLOpenWiki"
    'OPENWIKI_DB = "OpenWikiDist"


  • Moderators, Politics Moderators, Paid Member Posts: 44,040 Mod ✭✭✭✭Seth Brundle


    <%
    Dim myConn, connection
    set myConn = server.createobject("adodb.connection") 
    connection = "Driver={Mysql}; Server=localhost; Database=test; UID=root; PWD=root" 
    myConn.open(connection) 
    %>
    
    You may also need these after PWD=root
    Port=3306; Option=0; Socket=; Stmt=;
    


Advertisement