SQL Server连接字符串异步处理​​=真字符串、SQL、Server

2023-09-04 00:25:33 作者:思念蔓延成海

我使用的.Net 2.0 + SQL Server 2005企业+ VSTS 2008 + C#+ ADO.Net来开发ASP.Net Web应用程序。

I am using .Net 2.0 + SQL Server 2005 Enterprise + VSTS 2008 + C# + ADO.Net to develop ASP.Net Web application.

我的问题是,如果我使用异步处理=真与SQL Server身份验证模式(而不是Windows身份验证模式,即使用sa帐户和密码在网络连接字符串.config文件),我想知道是否异步处理=真将影响我的web应用程序的性能(或取决于我的ADO.Net code实现模式/场景)?为什么?

My question is, if I am using Asynchronous Processing=true with SQL Server authentication mode (not Windows authentication mode, i.e. using sa account and password in connection string in web.config), I am wondering whether Asynchronous Processing=true will impact performance of my web application (or depends on my ADO.Net code implementation pattern/scenario)? And why?

推荐答案

只是具有异步处理=真在连接字符串中只是简单地让你来写异步查询 - 我看不出有,在连接字符串中设置应该不会影响你的表现,如果你不改变任何东西。

Just having the Asynchronous Processing=True in your connection string just simply enables you to write asynchronous queries - I don't see how having that setting in your connection string should affect your performance, if you don't change anything else.

您将有望开始看到你的表现产生积极的影响,当你开始做你的数据库查询异步处理。但是,仅仅指定一个选项不会对您的应用程序的任何(正或负)的影响。

You will hopefully begin to see a positive effect on your performance when you start doing asynchronous processing of your database queries. But just specifying that one option shouldn't have any (positive or negative) impact on your app.

马克·