CLASSIC ASP - SQL Server does not exist or access is denied

I am trying to establish a connection to SQL Server Express DB on localhost, but I am getting the following error message:

Microsoft OLE DB Provider for SQL Server (0x80004005)

[DBNETLIB] [ConnectionOpen (Connect ()).] SQL Server does not exist or access is denied.

The code I'm using is

Dim connection 
Set connection = CreateObject("ADODB.connection") 
connection.connectionString = "server=localhost;Provider=SQLOLEDB;Data Source=RiskManagement;Initial Catalog=RiskManagement;User ID=sa;Password=myPass;" 
connection.Open() 

Any ideas?

+3
source share
2 answers

First of all, be sure to configure SQL Server for a remote connection.

How to configure SQL Server 2005 to allow remote connections

For general SQL Server connectivity troubleshooting information, see the following Blog Post

+3
source

, connectvity, ( Windows 10.10.10.10 AppServer) (, DBServer 10.10.10.11). , , , .

0

Source: https://habr.com/ru/post/1717421/


All Articles