Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Apr 2011
    Posts
    95
    Thanks
    13
    Thanked 1 Time in 1 Post

    dreamweaver-sql server connection

    I have managed to create a succesful connection and when i run a query into recordset area runs without problem.
    When i am trying to display data on internet explorer i get
    "The website cannot display the page
    HTTP 500"

    Probably something i am doing wrong with connectivity since i am not experienced.

    The dreamweaver connecion is this:
    Code:
    <%
    ' FileName="Connection_odbc_conn_dsn.htm"
    ' Type="ADO" 
    ' DesigntimeType="ADO"
    ' HTTP="false"
    ' Catalog=""
    ' Schema=""
    Dim MM_conntest_STRING
    MM_conntest_STRING = "dsn=test ;uid=username;pwd=12345;"
    %>


    When i log into management studio i use those info:
    Code:
    server type:database engine
    server name: username-PC\SQLEXPRESS
    authentication: windows authentication

    Any idea about what i am doing wrong?

  • #2
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    27,652
    Thanks
    80
    Thanked 4,638 Times in 4,600 Posts
    NightmareWeaver is stupidly only allowing you to use an ODBC connection, and I'm not sure at all that SQLExpress supports ODBC.

    You shouldn't be using a DSN with SQL Server in any case. It's slower and clumsier than a native connection.

    Try using one of the connection methods shown here:
    http://www.carlprothman.net/Default....erForSQLServer
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    garevn (11-01-2011)

  • #3
    New Coder
    Join Date
    Apr 2011
    Posts
    95
    Thanks
    13
    Thanked 1 Time in 1 Post
    ok so i think this is for me.

    Code:
    To connect to SQL Server running on the same computer
    
    oConn.Open "Provider=sqloledb;" & _
               "Data Source=(local);" & _
               "Initial Catalog=myDatabaseName;" & _
               "User ID=myUsername;" & _
               "Password=myPassword"

    should i replace my carrent connection page with this code?
    Also is there a possibility security issues on datavase occur this problem?

  • #4
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    27,652
    Thanks
    80
    Thanked 4,638 Times in 4,600 Posts
    >> should i replace my carrent connection page with this code?

    Yes. Or at least try it.

    >> Also is there a possibility security issues on database occur this problem?

    Maybe fewer issues than DSN would have. But they are probably identical in terms of security.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • #5
    New Coder
    Join Date
    Apr 2011
    Posts
    95
    Thanks
    13
    Thanked 1 Time in 1 Post
    Ok i am done man i had to make some changes on iis since i use 64bit os and work more an sql servers accounts-righs, and on string. thanks a lot


  •  

    Posting Permissions

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