I have two .net solutions. They both have this code:
var connectionString = "Server = ServerName; Database = DatabaseName; Trusted_Connection=True;"
var connection = new SqlConnection(connectionString);
And they both use complitely the same connectionString. And they connect to MSSQL Server;
And in the first solution connection.Open() succeeded and in the second one it failed. Error message : Named Pipes Provider, error: 40 - Could not open a connection to SQL Server
And every time I create new solution it fails. So this connection only works in one specific solution. And also, my teammates tested this and didn't have such issues.
Can you help with hints why it can be so?