Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2004
    Posts
    202

    Unanswered: Connect From ASP to SQL Server Through ODBC

    Hi there,

    I'm a new comer to this APS language and hope sombody out there can help me with this
    I'm trying to find codes for me to connect from ASP to Sql Server using ODBC.
    Can anyone help me
    Thanx

  2. #2
    Join Date
    Jan 2003
    Location
    India
    Posts
    523

    Re: Connect From ASP to SQL Server Through ODBC

    Originally posted by michaelfg81
    Hi there,

    I'm a new comer to this APS language and hope sombody out there can help me with this
    I'm trying to find codes for me to connect from ASP to Sql Server using ODBC.
    Can anyone help me
    Thanx


    Set db = Server.CreateObject("ADODB.Connection")
    db.Open "Provider=SQLOLEDB; Data Source=SERVER; Initial Catalog=database; User ID=username; Password=password"

    check this link :
    http://www.planet-source-code.com/vb...txtCodeId=6442

    regards,
    Harshal.

  3. #3
    Join Date
    Mar 2004
    Posts
    202

    Help

    Dear Harshal,

    Set db = Server.CreateObject("ADODB.Connection")
    db.Open "Provider=SQLOLEDB; Data Source=SERVER; Initial Catalog=database; User ID=username; Password=password"

    with this script above, isn't it connecting ASP to SQL Server via OLE DB?
    Is connecting via OLE DB and ODBC which i have to set in the Administrator Tool for it to work, the same?
    Thanx

Posting Permissions

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