Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 29th, 2003, 11:45 AM
Registered User
 
Join Date: Aug 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Server\NamedInstance not found

I am trying to make a connection to a named instance of a server that has a "\" in the name. In this case it is a SQL2000 Server instance (named: "SQLSERVER\SQLSERVER2000") that is running on a server that also has a SQL7 Server instance (named: "SQLSERVER") running on it. Using the following, I can connect to the SQL7 instance, but I'm getting an error messsage when I try to connect to the SQL2000 server instance:

Error Type:
Microsoft OLE DB Provider for SQL Server (0x80004005)
[DBNMPNTW]Specified SQL server not found.
/whitepapers/databases.asp, line 9


Here's an example of the connection that I'm trying to use:
<%
sConnect = "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sqluser;Initial Catalog=master;Data Source=SQLSERVER\SQLSERVER2000"
Set oConn = Server.CreateObject("ADODB.Connection")
oConn.Open sConnect
%>

Any Ideas?
 
Old September 1st, 2003, 03:00 AM
Authorized User
 
Join Date: Jun 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Firstly:
Check that the named instance of SQL server has actually been started.

 
Old September 1st, 2003, 03:06 AM
Authorized User
 
Join Date: Jun 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Secondly:
Check to see if you have to use the SQL Server switch facility to switch in the named instance from the default SQL Server 7 instance.

 
Old September 2nd, 2003, 09:16 AM
Registered User
 
Join Date: Aug 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for the replies. The service was definately started and I'm not sure what you were refering to with the "SQL Server Switch Facility"
I actually ended up getting the connection to work after updating the MDAC on the IIS Server. I think it was running on MDAC 2.1 or earlier; I updated it to 2.6. I had moved the page to another server and it found the SQL Server without problems there. After updating that it took me a few more tries but now it's found it without further errors.

 
Old September 2nd, 2003, 09:23 AM
Authorized User
 
Join Date: Jun 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi

I have since read that if you want to connect to a named instance of SQL Server you need to be using MDAC 2.6 anyway.

Try this link:
http://www.able-consulting.com/MDAC/...erForSQLServer

 
Old September 2nd, 2003, 09:32 AM
Registered User
 
Join Date: Aug 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

That's a great link. Thanks for passing it on, it's nice to have some verification that the MDAC is what needed to be fixed to solve the error. Thanks!

 
Old April 28th, 2004, 12:02 PM
Registered User
 
Join Date: Apr 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

MDAC 2.7 is installed, yet the error continues to reign. HELP!

 
Old April 28th, 2004, 10:31 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

What is your computer Name? Is that "SQLSERVER" itself? Or try giving the server IP address.

Also can you check if the Instance should be given as "SQL Server 2000" ? - with spaces in between. I searched a lot on sample instance name and found no clue, Still search is on, But I guess this there should be some problem with spelling it out there.

Will update you if I find something useful.

-Vijay G





Similar Threads
Thread Thread Starter Forum Replies Last Post
Server Error in '/' Application - Method not found Jan_Ma ASP.NET 1.0 and 1.1 Professional 1 October 27th, 2003 03:27 PM
Server Error in '/' Application - Method not found Jan_Ma Classic ASP Professional 0 October 16th, 2003 08:07 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.