Sqlcmd:错误:Microsoft SQL Server Native Client 11.0:SQL Server网络接口:找到指定的服务器/实例时出错[xFFFFFFFF]

时间:2016-11-01 11:55:22

标签: sql-server

当我尝试使用SQLCMD实用程序建立SQL Server连接时出现以下错误。

C:\WINDOWS\system32>sqlcmd -S <ComputerName>\<InstanceName>

Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : SQL Server Network Interfaces: Error Locating Server/Instance Specified [xFFFFFFFF]. .
Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : Login timeout expired.
Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online..

我们是否有解决此问题的解决方法。

2 个答案:

答案 0 :(得分:1)

SQLCMD -S。\ SQLEXPRESS -E - &GT;连接窗口验证 enter image description here

答案 1 :(得分:0)

添加端口号后,我可以使用SQLCMD Utility建立SQL连接。

C:\WINDOWS\system32>sqlcmd -S <ComputerName>\<InstanceName>,<SQL Port Number>
1> Use Master
2> GO
Changed database context to 'master'.
1> EXIT