I have a local SQL Server database, and I'm trying to connect to it apparently unsuccessfully:
new SqlConnection(@"Server=(localdb)\v12.0;Integrated Security=true;Database=MyDBName;");
However, this line throws an exception: "ServerVersion" throws an exception of type "System.InvalidOperationException"? What can I do to fix this?
I ran
sqllocaldb create "v12.0"
but it doesn't seem to matter.
source
share