Working with a Local Database File in Visual Studio

In this post and video I’ve shown folks how to work with a local database file (.mdf, .mdb, .sdf) that resides directly inside your project in order to see updates made while debugging your application. If it looks like everything saves fine while debugging, but you can’t see the updates if you look directly in the database, then there’s a simple fix. Today the VS Data Team wrote up a great blog post on this as well so check it out!

In general I prefer to develop against attached SQL Server databases because it’s easier to debug. But if you’re working with SQL Compact or Access databases you’ll need to be aware of how the database file is copied out with your application EXE and what file you are really working with.

Enjoy!