Print Page | Close Window

SQL Connection Error

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=27428
Printed Date: 02 April 2026 at 5:43pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: SQL Connection Error
Posted By: kjmay
Subject: SQL Connection Error
Date Posted: 02 June 2009 at 9:10pm
Running extranet site in-house on Windows Server 2000 using Windows NT authentication, IIS 5, accessing SQL 2005 on another server.  All other db apps on this extranet connecting to the same SQL 2005 server are running without problem.
 
I cannot get database_connection.asp to run correctly.  Our DB copied the scripts from 'msSQL_server_setup.asp' and created SQL 2005 tables through Query Analyzer.  The following code on a quick test page I created in the \forum subdirectory connects to the WebWizForums SQL database and successfully loops through writing returns values from the two records in the  tblAuthor table.
 
 set conn = Server.CreateObject("ADODB.Connection")
 conn.Open "Provider=SQLOLEDB.1;Password=CorrectPassword;User ID=CorrectID;Initial Catalog=WebWizForums;Data Source=CorrectServerName"
 Set rsReview = Server.CreateObject("ADODB.Recordset")
 vSQL = "SELECT * from tblAuthor"
 
 rsReview.Open vSQL, conn, 3, 3
 ...
 
Nothing I've tried in database_connection.asp will run correctly (name of server, TCP/IP #, commenting out code and inserting my own connection string, etc.).  I keep getting the error below when going to CorrectURL/forum or CorrectURL/forum/admin.asp

 
Server Error in Forum Application
An error has occurred while connecting to the database.
Please contact the forum administrator.

Support Error Code:- err_SQLServer_db_connection
File Name:- common.asp

Error details:-
Microsoft OLE DB Provider for SQL Server
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.

Any suggestions would be greatly appreciated.
 
Thanks,
Kathy



Replies:
Posted By: WebWiz-Bruce
Date Posted: 03 June 2009 at 7:22am
You can not use NT Authentication and a trusted connection. The SQL Server needs to be setup in mixed mode with TCP/IP connections enabled.

-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net