[英]Connection with informix database working in local but not working when website hosted on server
[英]Is there anyway to connect to local SQL Server database from hosted website?
我用SQL Server数据库创建一个网站,并将其放在主机上...
我只想知道是否有办法在特殊PC上打开网站时可以连接到PC的SQL Server数据库以进行读写...
让我知道是否有特殊的连接字符串!
您需要使用服务器IP地址以及用户ID和密码来连接数据库。
喜欢
<add name="DefaultConnection" connectionString="Data Source=198.0.0.1;Initial Catalog=Database;user id=user1;password=[system];" providerName="System.Data.SqlClient" />
IP-198.0.0.1用户ID-用户1密码-[系统]
注意 -
然后尝试。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.