connectivity issues in SQL Server 2005 with sqlcmd

  • what's the deal??? I know I am missing something but I can't figure it out. When I run sqlcmd -E I get a Named Pipes Provider: could not open a connection to SQL Server [2].

    when I rund sqlcmd -E -S.\SERVER I get 1>

    does this mean that there is a parameter somewhere that specifies default connection, or what? I don't know I am just guessing right now. It is causing a problem with SQL Server service...the error in the application event viewer is Failure Audit: Login failed for user 'NEWMEXICO\Administrator'. [CLIENT: ] error code 18456. And it's annoying...can anyone help???

    Thank you,

    Daniel

  • I am not sure I understand your problem. What is the code you are running that does not work? Because running sqlcmd -E -S.\Server is connecting to the local server\instance that is what the 1> means. That is where you then execute your T-SQL statements followed by a GO when you have completed the batch.

  • I am just trying to connect using the following command

    c:\>sqlcmd -E

    I have another sql server where this command works. The second sql server fails with this command.

    However, if I use the following:

    c:\>sqlcmd -E -S.\Server

    then I can connect into the second sql server.

    This is the only difference I have found between the servers. I wouldn't care either way except that the sql server agent gives an invalid username/password in the application error log and i get dbfaults within the vault, the software that is trying to connect to these two sql servers.

  • I am just trying to connect using the following command

    c:\>sqlcmd -E

    I have another sql server where this command works. The second sql server fails with this command.

    However, if I use the following:

    c:\>sqlcmd -E -S.\Server

    then I can connect into the second sql server.

    In the second example you are connecting to a Named Instance of Sql Server. The ".\Server" essentially means LocalHost\Server. You can install Sql Server 2000 forward on the same machine multiple times using Named Instances. When you install the first one and select Default instance you can use the first example, but when you have a named instance you must include the server name (the ".") and the instance name ("Server"). The instance name follows a "\".

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply