0
votes

Im getting this error but there is no documentation to fix my problem i just installed SQLExpress 2008 created the instance name SQLExpress choose mixed mode and I choose SQL Server Authentication for authentication user which is KIRK-PC\KIRK(also tried sa with sa I get login failed) and password which is pass. Can some one help do the steps to fix this problem


Cannot connect to localhost.


ADDITIONAL INFORMATION:

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: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (Microsoft SQL Server, Error: 2)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&EvtSrc=MSSQLServer&EvtID=2&LinkId=20476


BUTTONS:

OK

1
how exactly are you connecting to it? do you have multiple instances of sql server installed?Mitch Wheat
Just one instance fresh install on fresh windows installONYX
I think what mitch was after is the exact code you are using to access your instance. In particular, the connection string.NotMe
No Im trying to login in Management Studio I haven't yet created a page to connect to a database yetONYX

1 Answers

1
votes

Make sure TCP/IP is turned on. I think the Express edition has it off by default. Go to Configuration Tools > Sql Server Configuration Tools then click Protocols for SQLExpress (or whatever your instance name is) then make sure TCP/IP is enabled.