Jibz
✅ cannot connect console dotnet project with microsoft SQL
I'm following this : https://learn.microsoft.com/en-us/azure/azure-sql/database/connect-query-dotnet-core?view=azuresql-mi
I'm running microsoft sql from docker. I can access my database from azure data studio by setting server as "localhost" so I tried to do the same in my code. My confusion is here
builder.DataSource = "<your_server.database.windows.net>";
setting "server" in azure data studio works so I thought it should work as well in code but it throws error when I do this:
builder.DataSource = "localhost";
or this
builder.DataSource = "localhost.database.windows.net";
What am i doing wrong?4 replies