在线后输出错误但在本地运行正常 [英] Geeting an error after online but in Local it runs fine

查看:106
本文介绍了在线后输出错误但在本地运行正常的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遇到这个错误: -



建立与SQL Server的连接时发生网络相关或特定于实例的错误。服务器未找到或无法访问。验证实例名称是否正确,以及SQL Server是否配置为允许远程连接。 (提供者:SQL网络接口,错误:26 - 错误查找指定的服务器/实例)



网站运行完美,但每当我点击我的网站上的添加到购物车选项然后它显示错误,plz plz解决任何人...........

I am Getting this one error:-

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

the website runs perfectly but whenever i click on add to cart option on my website then it shows the error,plz plz solve anyone...........

推荐答案

检查下面列出的三点:

1.确保您的数据库引擎配置为接受远程连接(我使用的是集中式数据库)

Check the three points listed below:
1. Make sure your database engine is configured to accept remote connections(I you are using centralized database)
引用:

•开始 - >所有程序 - > SQL Server 2005 - >配置工具 - > SQL Server表面区域配置

•单击服务和连接的表面区域配置

•选择出现问题的实例 - >数据库引擎 - >远程连接

•启用本地和远程连接

•重新启动实例

•Start -> All Programs -> SQL Server 2005 -> Configuration Tools -> SQL Server Surface Area Configuration
•Click on Surface Area Configuration for Services and Connections
•Select the instance that is having a problem -> Database Engine -> Remote Connections
•Enable local and remote connections
•Restart instance



2.检查SQL Server服务帐户


2. Check the SQL Server service account

Quote:

•如果您没有将域帐户用作服务帐户(例如,如果您使用的是NETWORK SERVICE) ,您可能希望在继续之前先切换它

•If you are not using a domain account as a service account (for example if you are using NETWORK SERVICE), you may want to switch this first before proceeding



3.如果您使用的是命名的SQL Server实例,请确保在ASweb P的连接字符串中使用该实例名称.NET应用程序


3.If you are using a named SQL Server instance, make sure you are using that instance name in your connection strings in your ASweb P.NET application

Quote:

•通常,指定数据库服务器所需的格式为machinename \instancename

•检查您的连接字符串。

•Usually the format needed to specify the database server is machinename\instancename
•Check your connection string as well.



请参考以下链接:

建立与SQL Server的连接时发生网络相关或特定于实例的错误 [ ^ ]





--Amit


Refer the link below:
A network-related or instance-specific error occurred while establishing a connection to SQL Server[^]


--Amit


抛出此问题的原因可能是服务器名称错误,禁用远程连接和防火墙阻塞。



请通过此link [ ^ ]。

< br $>
更新:



HTTP://technet.m icrosoft.com/en-us/library/cc739791%28v=ws.10%29.aspx#BKMK_4 [ ^ ]



http://msdn.microsoft.com/en-us/library/cc646023.aspx [ ^ ]
The reasons for throwing this issue could be wrong server name, disabled remote connection and firewall blocking.

Please go through this link[^].

Update:

http://technet.microsoft.com/en-us/library/cc739791%28v=ws.10%29.aspx#BKMK_4[^]

http://msdn.microsoft.com/en-us/library/cc646023.aspx[^]


那我怎么能远程连接和防火墙阻止????? plz plz ans me .......
so how can i able remote connection and firewall block?????plz plz ans me.......


这篇关于在线后输出错误但在本地运行正常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆