Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Connection to Default Instance of SQL Server 2016 LocalDB

Need help getting SQL Server 2016 LocalDB to accept connections using default instance name "(localdb)\MSSQLLocalDB". I can get a connection using "(localdb)\.". OS is MS Windows 10 Pro 64 Bit. Have Visual Studio 2015 Express Update 3, SQL Server 2016 Local DB (also 2014), SQL Server Data Tools (latest update), and SQL Server 2012 Native Client installed. MSSQLLocalDB instance is created and will start using sqllocaldb.exe. Have same setup on a Windows 7 machine and it works fine. Have searched the web for a solution to this, but did not find any that applies to my case. Thanks.

like image 765
user6611272 Avatar asked Jul 20 '16 02:07

user6611272


1 Answers

I was able to solve the problem by removing the alias for MSSQLLocalDB in both 32 and 64 bit versions of cliconfg.exe. Server name was: (LocalDB)\MSSQLLocalDB and pipe name was (localdb)\MSSQLLocalDB. The alias may have been created during the installation of a previous version of Visual Studio. I noticed that the Windows 7 machine did not have this alias. Hope this helps someone else with similar problem.

like image 158
user6611272 Avatar answered Oct 07 '22 01:10

user6611272