I installed the LocalDB component (only) from SQL Server 2019 Express on a Windows 10 machine that had NO Sql Server installation of any kind. I installed SSMS next.
The AUTOMATIC instance MSSQLLOCALDB works as advertised. I can use SSMS to access it, add a database, perform queries, everything is fine.
I want to make this instance shared.
So I typed (from Powershell) sqllocaldb share MSSQLLOCALDB SharedDb
The shared instance is properly created.
PS C:\WINDOWS\system32> sqllocaldb i
.\SharedDb
MSSQLLocalDB
But I cannot access the shared instance from SSMS
Things I have tried
- Stopped and started the automatic instance
- used the servername as (localdb)\.\SharedDb as documented.
- tried it from sqlcmd where it works for the automatic instance, but fails for the shared instance.
- rebooted the machine
Fails with: Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : Named Pipes Provider: Could not open a connection to SQL Server [2]. . Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : Login timeout expired. Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online..
Any suggestions on how to share a LocalDB instance would be appreciated. Thanks.