This course will be retired on July 14, 2025.
Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
- What are Migrations? 4:41
- Enabling Migrations 6:06
- Code First Migrations Review 5 questions
- The Configuration Class 2:09
- Adding Our First Migration 4:05
- The Migration Fluent API 6:04
- Updating the Database 4:13
- Populating Our Database with Seed Data 7:31
- Using the Configuration Class to Add Seed Data 1 objective
- Excluding Test Data in Production 5:54
- Using a Preprocessor Directive to Exclude Test Data 1 objective
- Section Review 10 questions

- 2x 2x
- 1.75x 1.75x
- 1.5x 1.5x
- 1.25x 1.25x
- 1.1x 1.1x
- 1x 1x
- 0.75x 0.75x
- 0.5x 0.5x
Let's start with a look at the challenge of maintaining our data model after our application has been released into production and how Code First Migrations helps us with propagating data model changes to the database. We'll also review what you'll learn in this course.
Prerequisites
To get the most from this course, you should feel comfortable with C#, Visual Studio, and the basics of Entity Framework. For more information about those topics, check out these Treehouse courses and workshops:
While it's not absolutely required, you'll also find it helpful to know something about relational databases and the SQL language. Check out this Treehouse course:
Additional Learning
For more information about the EF Code First workflow or Code First Migrations, see the following MSDN (Microsoft Developer Network) resources.
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up-
Hakim Rachidi
38,490 Points1 Answer
View all discussions for this video
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up
You need to sign up for Treehouse in order to download course files.
Sign upYou need to sign up for Treehouse in order to set up Workspace
Sign up