开发者

Named Pipes Provider, error: 40 - Could not open a connection to SQL Server 2008 in .net application [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and c开发者_高级运维annot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 11 years ago.

I am using .net application by sql server 2008 remote access. The error in application are "An error occurred while establishing a connection to server. When connecting to SQL Server 2008, this failure may caused by the fact that under the default settings SQL Server does not allow remote connections. (Provider:Named pipes Provider error:-40 - Could not open a connection to sql server.


Your SQl server is ether doesn't allow your remote access so if you want to access remote server allow tcp/ip connections or your connection string is wrong. In either case you should post your connection string without servername username password in here so we can check the validity.

Just one note, allowing external tcp/ip connections to SQL-SERVER is not secure because anyone can access the server from now on. I would advice to limit access in firewall or managed switch by restricting access to IIS or application server IP.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜