SQLCMD Returning Named Pipe Error I am trying to run any command from SQL Server Express from the command line using sqlcmd. Here is an example.

sqlcmd -U myname-P mypwd -S mysys/SQLEXPRESS -d MASTER -Q "Select count(*) from sys.databases"


I keep getting the error below. It appears to be trying to connect using named pipes, but I have configured SQL Express to use TCP.  How can I get SQLCMD to not use the named pipes?

Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Named Pipes Provider: 
    Could not open a connection to SQL Server [67]. .
Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Login timeout expired.
Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server :
    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..
Server name and instance name should be separated by a backslash, not a forward slash. Try:

sqlcmd -U myname -P mypwd -S mysys\SQLEXPRESS -d master -Q "Select count(*) from sys.databases"