Geeks With Blogs
Magnus Karlsson
This is my first blog post and will be short and concise. I will get back to formatting later.

Edit: Here is the same explanation but from MSDN :)

Been playing around with MVC, Scaffolding and Razor a couple of weeks now on my spare time. Think I should write som stuff down here to share with others!

I started out here, thanks to Steve Sanderson!

However, what is not included is how to set up your database if you prefer to use MS SQLSERVER instead of EXPRESS. 
Take the name of the persistence class (probably NAMEOFPROJECTcontext.cs) in you models folder and use it like I use TestProject here.

<add name="TestContext"
        connectionString="Server=.;Database=TestContext.mdf;Integrated Security=SSPI;"
        providerName="System.Data.SqlClient" />

This created a TestContext.mdf database directly when my Initializedb ran.
Posted on Wednesday, February 29, 2012 5:13 PM | Back to top

Comments on this post: Entity Framework 4.1 Code First- Use MSSQLSERVER instead of EXPRESS

No comments posted yet.
Your comment:
 (will show your gravatar)

Copyright © Magnus Karlsson | Powered by: