Connecting to SQL server from another computer

て烟熏妆下的殇ゞ 提交于 2019-12-04 15:10:20

There are few things you should check:

  1. Remove "Trusted_Connection=True;" in your connection string

  2. Turn off the firewall on both machines for testing. If it works, you can enable the both of them and then configure the access rights for specific application

  3. Enable SQL Authentication on SQL Server instance: http://kbase.gfi.com/showarticle.asp?id=KBID002804

  4. Simple way to test it works or not without running your c# code: you can install the SQL Management Studio on the code-machine and try to connect the SQL Server instance.

Hope it helps.

Manage sa account in sql server with username= sa and set password=---- Use this connection string where 1433 is TCP Port

(Server=server_name,1433;Database=------;User ID=sa; Password=-----");
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!