Today I will give a brief introduction about Entity framework and how to implement Entity framework in MVC.
What is Entity framework?
Entity framework is an ORM (Object Relational Mapping) tool.

Object Relational Mapping (ORM) is a technique of accessing a relational database; .i.e., whatever has tables and store procedure these things we interact with database in class, method and property of the object format.
Features of ORM in entity framework
- Map our database types to our code types
- Avoid repetitive data access code
- Access code automatically based on the data model class
- Support a clean separation of concerns and independent development that allows parallel, simultaneous development of application
- Easily reuse the data object
- Application Maintainability
How to Install and Update using NuGet
Install-Package EntityFramework
Update-Package EntityFramework
Now we will see the practical from basic so first we will start using console application and how to use entity framework in console application so for this, open the visual studio and go file option and select console and click okay

And click OK
After opening the console application, Entity framework is not installed by default.

In the above pic, it has not installed Entity framework so first we will install the Entity framework.
Go to Tools option ->New Get Package Manager -> Package manager

After that write the command “Install-Package EntityFramwork” in command window

And press enter.
Or you can check this link for all versions
In Entity framework we follow the three approaches for communicating with database
- Database First
- Code First
- Model First
Now we have to add Entity so here I am going to use database first approach when we have an already-existing database then we will prefer the database first approach. So for this right click our solution explorer and go add and select data in left panel and then select ADO.Net Entity Data Model.







Dinorego MphogoPosted Aug 28, 2018, 7:35 AM
Hi Mithilesh, I have followed your instruction on VS 2018 on Console application but I have challenges with with creating an object on line 8 "ExampleDBEntities objEntity = new ExampleDBEntities();" what exactly do you create a class ExampleDBEntities? and what does it represent as part of Entity Framework?
Farhan AhmedPosted Jul 24, 2018, 3:37 AM
Like it. Add stored procedure too
Hiten PandyaPosted Jul 8, 2018, 11:30 PM
Good Startup for beginners in Entity with Straight forward write up.