本文介绍了从ASP.Net到SQL的Windows身份验证连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





我创建了一个使用SQL Server身份验证连接到sql server的应用程序,如下所示



add name =ConnectionStringconnectionString =Data Source = hostname; Initial Catalog = databasename; User ID = UID; Password = pwdproviderName =System.Data.SqlClient



现在我想使用Windows身份验证建立连接,即坚持安全信息=真;



你能帮助我改变我应该做的在我的ASP.Net应用程序和SQL服务器数据库中



提前谢谢

Hi,

I have created an application which connects to sql server using SQL server authentication as shown below

add name="ConnectionString" connectionString="Data Source=hostname;Initial Catalog=databasename;User ID=UID;Password=pwd" providerName="System.Data.SqlClient

Now i want to make connectivity using windows authentication i.e Persist Security Info=True;

Can you please help me with the changes that i should make in my ASP.Net application and in SQL server database

Thanks in advance

推荐答案


<add key="ConnectionString" value="Data Source=hostname;Database=databasename;Integrated Security=SSPI;" />



这篇关于从ASP.Net到SQL的Windows身份验证连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-21 00:11