Named Pipes Provider: Could not open a connection to SQL Server [2]

Hi

I'm a complete sql/asp.net newbie and want to try this tutorial:
http://beta.asp.net/GuidedTour/

First I installed:
Visual Web Developer 2005 Express Edition Beta 2

systemsettings\software shows the "sql server 2005 express edition ctp (sqlexpress)" installed

mmc\service shows me the SQL Server (SQLExpress) is running

Following the guided tour I use the commandline, type cmd, and type in the commandbox:
"C:\Program Files\Microsoft SQL Server\90\Tools\binn\SQLCMD90" -S "localhost\SqlExpress"

Instead of localhost I also tried computername.smallbusiness.local (thats my fully domain name).

However I always receive the error:

Named Pipes Provider: Could not open a connection to SQL Server [2]

Thank you very much for all your help

[1005 byte] By [zipfeli] at [2008-2-7]
# 1

I have the same error. Anybody has a solution for this? I did the standard install too!

JulianKooiker at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...
# 2
I get the same (I did enable the Named Pipes provider in Configuration Manager, but it made no difference) only if I omit the server name completely; if I use the sqlcmd -S server\instance format that everywhere tells you to, I get:

'Sqlcmd: Error: Internal error at OpenDataSourceDirect (Reason: Unspecified error).
HResult 0x57, Level 16, State 1
SQL Network Interfaces: Connection string is not valid [87].
Sqlcmd: Error: Microsoft SQL Native Client : Client unable to establish connection.
Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.'
If I try to connect through VC# Express I get the message:

'Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.' (but here it's using the .Net provider).

Please, please, please can someone tell me what I'm doing wrong. I have spent days trying to get this to work. I even uninstalled and re-installed the whole of SQL Express, VC# Express and .Net, which was no easy task!!. I am DESPERATE!

LesleyW at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...
# 3
LesleyW wrote:
I get the same

I have actually just noticed that the message I get is:

Named Pipes Provider: Could not open a connection to SQL Server [53], rather than [2], so I guess it's not quite the same error...

LesleyW at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...
# 4
Get Computer Name from System Properties->Full computer Name.
after this

from command prompt run >sqlcmd -S<computerName>\SQLEXPRESS -E

This worked for me, hope it does for you.

RameshKasavaraju at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...
# 5
Having uninstalled SQL Express, VC# and .Net AGAIN. I discovered that if I let VC# install SQL Express, rather than me doing it first (as I had done previously), then I can connect no problem. Don't know why...
LesleyW at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...
# 6

I was trying to install the Northwind database into SQLServer 2005 express server when I got the error,

'Named Pipes Provider: Could not open a connection to SQL Server [2]'.

This solution worked for me

1) Start SQL Server Configuration Manager

Right-click on the sql server name that you created

Select 'Properties'

On the 'Log On' tab, set the 'Log on as: '

Built in account, Local System

Restart Service and close Sql Server Config Mgr

2) Go to the DOS command prompt

CD <directory where .sql file to load databases resides>

sqlcmd -E -S <computername\SQL Servername> -i instnwnd.sql

Hope this helps someone else.

"T"

MyInput at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...
# 7

guys!!! you got to add sqlsvr to the exception in windows firewall.. why? coz you have installed a server and communication with the port to the server is blocked by the firewall.

nitingoyal28 at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...

SQL Server

Site Classified