Cannot get data from SQL Server 2012
当我尝试登录我的网站时,发生错误。 我也尝试过运行SQL服务。
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
连接字符串
1 | Data Source=.\\SQLEXPRESS (metro);Initial Catalog=metrodb;Integrated Security=True |
根据您的连接字符串,您正在尝试连接到名为
通常,如果您不更改任何默认值,则仅为
1 | Data Source=.\\SQLEXPRESS;Initial Catalog=metrodb;Integrated Security=True |
转到
您应该至少看到一个已启动的