5 Replies - 11839 Views - Last Post: 04 February 2012 - 02:55 PM

#1 solomon201  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 27
  • Joined: 19-November 07

Error When trying to add Service-Based Database

Posted 02 February 2012 - 03:12 AM

I have a project and when i try to add a service-based database file ".mdf" i get this error. I checked that my SQL server browser is running, The default TCP/IP port is 1433 but still getting the error (Provider: Named pipes Provider, error:40-Could not open a connection to SQL Server)

Thanks for all your help in advance
Is This A Good Question/Topic? 0
  • +

Replies To: Error When trying to add Service-Based Database

#2 modi123_1  Icon User is online

  • Suitor #2
  • member icon



Reputation: 13489
  • View blog
  • Posts: 53,887
  • Joined: 12-June 08

Re: Error When trying to add Service-Based Database

Posted 02 February 2012 - 07:55 AM

What's your connection string? Is the database installed locally? It sounds like it probably isn't..
Was This Post Helpful? 0
  • +
  • -

#3 solomon201  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 27
  • Joined: 19-November 07

Re: Error When trying to add Service-Based Database

Posted 02 February 2012 - 08:36 AM

yes its installed locally and I am trying it as a new Item.

I am using Visual Studio 2010 Ultimate and I have SQL Server 2008 R2 Installed

Add New Item-> Service-Based Database
Was This Post Helpful? 0
  • +
  • -

#4 Ionut  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 386
  • View blog
  • Posts: 1,057
  • Joined: 17-July 10

Re: Error When trying to add Service-Based Database

Posted 03 February 2012 - 06:06 AM

Enable Named Pipes protocol from SqlServer Configuration.
Start->Programs>Microsoft SqlServer 2008 R2->Configuration Tools -> SqlServer Configuration Manager
->Sql Server Network Configuration -> Protocol for <instance_name> - > Enable Named Pipes
->Sql Native Client 10.0 Configuration-> Client Protocols -> Enable Named Pipes
Was This Post Helpful? 0
  • +
  • -

#5 solomon201  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 27
  • Joined: 19-November 07

Re: Error When trying to add Service-Based Database

Posted 04 February 2012 - 06:42 AM

I have done that and I am still getting the error cannot open connection
Was This Post Helpful? 0
  • +
  • -

#6 Ionut  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 386
  • View blog
  • Posts: 1,057
  • Joined: 17-July 10

Re: Error When trying to add Service-Based Database

Posted 04 February 2012 - 02:55 PM

Same error or another one?
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1