0

I have a machine with Windows 7 and SQL Server 2008 R2.

With my application I can't connect to SQL Server from 2 PC,

  • 1 with Windows 7

  • 1 with Windows 10

I receive the same error:

Named Pipes Provider, error 40 - Could not open a connection to SQL Server

I have another machine in the same LAN with Windows XP and it can connect to SQL Server without problem.

The connection string is:

connectionString="Password=xxxx;Persist Security Info=True;User ID=xxxx;Initial Catalog=REPORTDB;Data Source=NW03SH02;Integrated Security=False"

The machine with SQL Server is named: NW03SH02 and the instance of SQL Server is named NW03SH02.

EDIT:

The solution isn't in other discussions of StackOverflow.

Now the connection with database works fine. I have to changed parameter Data Source in connection string from name of PC with SQL Server to IP of PC with SQL Server.

chianta
  • 123
  • 1
  • 2
  • 12
  • 1
    The problem is that it sounds like you don't have named pipes enable on your instance, or maybe the service isn't running. Google the error message. It has been asked and answered thousands of times. – Sean Lange Feb 07 '18 at 16:35
  • I have found other thread about this problem, but anyone of answers hasn't helped me. Service is running, named pipe is enable – chianta Feb 07 '18 at 18:10

0 Answers0