Have been getting the following error in SharePoint from a custom web part which tries to connect to a SQL Server 2008 SP1 database
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)
Spent several hours diagnosing the problem. The solution is as follows
Start SQL Server Configuration Manager. Click on “Protocols for MSSQLServer”. Enable TCP/IP (which is disabled by default).
0 Responses to “ASP.net Connectivity to SQL Server 2008 SP1”