我可以在asp.net中的单个web.config中提供多少个连接 [英] how many connection can i give in single web.config in asp.net
本文介绍了我可以在asp.net中的单个web.config中提供多少个连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我可以在asp.net的单个web.config中声明多少个连接字符串,以及如何在应用程序中使用它们?
how many connection strings can i declare in a single web.config in asp.net and how can i use them in an application ?
推荐答案
http://bytes.com/topic/asp-net/answers/727537-multiple -connection-string-web-config [
您可以根据需要在web.config中添加连接字符串(所需的数据库连接数)
You can add the connection string as per your requirement(the number of database connection required) in web.config
<connectionStrings> <add name="constr1" connectionString="..."/> <add name="constr2" connectionString="..."/> <add name="constr3" connectionString="..."/> <add name="constr4" connectionString="..."/> ... </connectionStrings>
根据您需要的数据库使用正确的连接字符串.
use proper connection string as per the database you need.
这篇关于我可以在asp.net中的单个web.config中提供多少个连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文