BT

New Early adopter or innovator? InfoQ has been working on some new features for you. Learn more

LocalDB: A Lightweight SQL Express for Developers

| by Jenni Konrad on Jul 14, 2011. Estimated reading time: 1 minute |

As part of SQL Denali CTP3, Microsoft has included a new version of SQL Express called Local Database Runtime (LocalDB). It offers many of the same features as SQL Express, but installs faster, has fewer prerequisites, and doesn’t require management of a database instance.

LocalDB is meant to be an easier way for developers to get a SQL Express database up and running with minimal configuration or management, but it can also be used in production if it suits the needs of an application. Because it opens as a file with exclusive use, LocalDB is not appropriate for server-based or multi-user environments.

LocalDB fully supports T-SQL, and uses the same client-side providers as other versions of SQL Server (ADO.NET, ODBC, etc). It runs in-process, rather than as a service. When an application connects to LocalDB, the provider checks to see if it’s already running, and if not, will start it up and connect. The connection closes automatically after a few minutes of inactivity.

The database supports AttachDbFileName, so the connection to LocalDB is straightforward:

"Data Source=(localdb)\v11.0;IntegratedSecurity=true;AttachDbFileName=C:\MyData\Database1.mdf"

Microsoft states that they intend to provide a LocalDB download option in the future. For now, developers can demo it by downloading the SQL Denali Express CTP3 and selecting the LocalDB option during installation.

Rate this Article

Adoption Stage
Style

Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread
Community comments

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Discuss

Login to InfoQ to interact with what matters most to you.


Recover your password...

Follow

Follow your favorite topics and editors

Quick overview of most important highlights in the industry and on the site.

Like

More signal, less noise

Build your own feed by choosing topics you want to read about and editors you want to hear from.

Notifications

Stay up-to-date

Set up your notifications and don't miss out on content that matters to you

BT