In Model First Approach, one need to create an Entity Model. If don't know about the Entity Model Creation o through the "Creation of Entity Framework" which is the previous article.
Elements
Entities
Relationships
Inheritance
Step-1
Based on the Entities created earlier, SQL commands can be created.
Follow the below steps to work with Model First Approach.
Open a New Project as shown in the below figure.
Step-2
Then, a new window will open. Select Visual C# ->Windows -> Console Application->Give the Name as per requirement and click on OK as shown in the below figure.
Now, the project will be created as shown in the below figure.
Step-3
Go to Solution Explorer->Right click on the Project->Add ->New Item as shown in the below figure.
Step-4
Then, a new window will opened as shown in the below figure. Select Data->ADO.NET Entity Model->Give the Name as required and click on Add as marked in the below figure.
Step-5
Then, the following window will be opened. Select the Empty Model and click on Finish as shown in the following figure.
The diagram will be generated as shown below.
Step-6
Right click on the empty space. Click on Add->Entity as shown in the below figure.