1、如果用(local)\sqlexpress登陆的数据库,C#连接字符串怎么写? string connString = @"Data Source=localhost\SQLEXPRESS;Initial Catalog=Test;Integrated Security=True"; nitial Catalog=Test; 就是初始选择哪一个数据库, 我这里是 Test , Data Source=localhost\SQLEXPRESS; 我这个是 SQL Server Express 版本的, 因此是这个地址。 如果你安装的是正式版本的, 那就是 Data Source=localhost