SqlConnectionLocalDB named instance via the named pipes pipe name

The Server=(localdb) syntax is not supported by .NET framework versions before 4.0.2. However the named pipes connection will work to connect pre 4.0.2 applications to LocalDB instances.


Executing SqlLocalDB.exe info MyInstance will get you (along with other info) the instance pipe name such as "np:\\.\pipe\LOCALDB#F365A78E\tsql\query".


This connection string (LocalDB named instance via the named pipes pipe name using SqlConnection) can be used for connections to SQL Server 2012, SQL Server 2014 and SQL Server 2016.

Articlesread all »

Not the right connection string for you?

Start over in the connection string reference index.

You can also get help in the Q&A forums where you can ask your own question.

The kb articles contains how-tos and instructions and you can search for anything if you're not sure were to look.