lap around entity framework
TRANSCRIPT
Lap Around Entity Framework
Jaliya Udagedara
What are we going to discuss today?A brief history of Entity FrameworkDeveloper workflowsDemo
Model FirstDatabase FirstCode First
What’s new in EF5?What’s new in EF6?Capabilities of the Entity FrameworkWhy use Entity Framework?
A brief history of Entity Framework
Entity Framework 4.3
Entity Framework (or EF 3.5)
Entity Framework 4.2
Entity Framework 4.1
Entity Framework 4
Entity Framework 5
Entity Framework 6
Entity Framework 6++
The initial release. .NET 3.5 SP1 and Visual Studio 2008 SP1.
.NET 4.0 and Visual Studio 2010.
.NET 4.0 / 4.5 and Visual Studio 2010 / 2012.When targeting .NET 4.5,
• enum support
• table-valued functions
• spatial data types
• various performance improvements.
.NET 4.0 / 4.5 / 4.5.1 and Visual Studio 2010 / 2012 / 2013.
Developer workflows
NewDatabas
e
ExistingDatabas
e
Designer Centric Code Centric
Database FirstReverse engineer model in EF DesignerClasses auto-generated from model
Model FirstCreate model in EF DesignerGenerate database from modelClasses auto-generated from model
Code FirstDefine classes and mapping in codeEF Power Tools provide reverse engineer
Code FirstDefine classes and mapping in codeDatabase created from codeMigrations apply model changes to database
I want to use a designerI am creating a new database
Model FirstI need to access an existing database
Database First
I want to write some codeI am creating a new database
Code FirstI need to access an existing database
Code First
Demo• Model First• Database First• Code First• New Database• Existing Database
What’s new in EF5?Code First & EF DesignerEnum SupportSpatial data typesPerformance Improvements
Code First OnlyDbContext Code GenerationMultiple diagrams and coloringTable-valued Functions
What’s new in EF6?Code First & EF DesignerAsynchronous query and saveConnection resiliencyCode-based configurationDatabase command interception/loggingPerformance improvements
Code First OnlyCustom conventionsInsert, update, & delete stored procedures
Capabilities of the Entity FrameworkWorks with a variety of database serversRich mapping engineSupport for Stored proceduresVisually create entity models/auto-generate models from an existing databaseCode First experienceIntegrates well into all the .NET application programming models
WPF, ASP.NET, WCF, and WCF Data Services
Why use Entity Framework?Reduced development time.
Provides dedicated functionality for CRUD operation.Easily managing “one to one", “one to many", and "many to many" relationships.Conceptual model that is independent of the physical/storage model.LINQ support (called LINQ to Entities).
Thank You!http://www.jaliyaudagedara.blogspot.com/