Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Issues establishing a connection to Azure SQL Database using Connection string via a WCF Service

I'm having trouble connecting to a SQL Database hosted on Azure, via a WCF Service I created. I got the connection string from Azure itself by clicking on the link.

Things i have done:

  1. Added the Public IP of my WCF service to the firewall settings of my Database Server.
  2. Allowed access to Azure Services
  3. Tried Connecting to the SQL Server via VS2015 by clicking on Tools>Open in Visual Studio

Here is my ADO.NET(SQL authentication) Connection string if it helps:

Server=tcp:thebutlrserver.database.windows.net,1433;Data Source=thebutlrserver.database.windows.net;Initial Catalog=btlrDB;Persist Security Info=False;User ID=******;Password=******;MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=False;Connection Timeout=120;

The Error I'm getting is:

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)

like image 381
Gys Rademeyer Avatar asked Oct 21 '25 13:10

Gys Rademeyer


1 Answers

Hi all i was able to fix this issue by Going to Uninstall or change a program> Turn Windows features on or off> en just enabling everything

like image 179
Gys Rademeyer Avatar answered Oct 23 '25 04:10

Gys Rademeyer



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!