Setting Up Entity Framework: Thomas Claudius Huber
Setting Up Entity Framework: Thomas Claudius Huber
@thomasclaudiush www.thomasclaudiushuber.com
Module
Outline
Plan the data access layer
Create and seed the database with
Entity Framework Code First
Load data in the FriendDataService
Plan the Data Access Layer
DataService
Friend
FriendOrganizer.DataAccess
Entity Framework SQL Server
Demo Create a DbContext subclass
Add a code first migration
Add constraints
Create and seed the database
Add Constraints
DataService
Friend
FriendOrganizer.DataAccess
Entity Framework SQL Server
Setting up Entity Framework
Summary - Create the DbContext
- Add a code first migration
- Create and seed the database