在c#项目中连接sql数据库
时间:2021-07-01 10:21:17
帮助过:16人阅读
1.0" encoding=
"utf-8"?>
<configuration>
<connectionStrings>
<add name=
"keys" connectionString=
"Data Source={0};uid={2};pwd={3};Initial Catalog={1};" providerName=
"System.Data.SqlClient;pooling=true;Max Pool Size=1000;Min Pool Size=30;Connect Timeout=1000"/>
<add name=
"LBDatabaseEntities" connectionString=
"metadata=res://*/Model1.csdl|res://*/Model1.ssdl|res://*/Model1.msl;provider=System.Data.SqlClient;provider connection string="data source=WIN-NRF4E4F71BM;initial catalog=LBDatabase;user id=sa;password=sa.123456;MultipleActiveResultSets=True;Connect Timeout=2000;App=EntityFramework"" providerName=
"System.Data.EntityClient"/>
</connectionStrings>
<startup>
<supportedRuntime version=
"v4.0" sku=
".NETFramework,Version=v4.5"/>
</startup>
</configuration>
WIN-NRF4E4F71BM 电脑名称(或者服务器实列名称)
LBDatabase 是数据库名称
sa 是数据库账号
sa.123456 是数据库密码
在c#项目中连接sql数据库
标签:ted system odi metadata name tab ase 服务 color