Sunday, December 6, 2020

CRUD Operation In ASP. Net Core Web API with Entity Framework Core

This article will explain how to perform CRUD (Create, Read, Update, Delete) operations in Asp.Net Core Web API using Entity Framework Core. We will see step by step instructions about CRUD operations in Asp.Net Core Web API. In this demonstration, we will use the Database First Approach where our database will be ready before creating an actual code.

Create the Database and Tables
Create Asp.Net Core Web API Project
Install Nuget Packages for Entity Framework
Generates Model Classes
Setup Dependency Injection
Create Repository and implement CRUD operations
Create a Controller and Create API call
Test the API End Points in Postman
Enable CORS


Steps - 1 Create Database 
   
tables 

Step - 2 Project - asp.net core 

  setup connection string and install some dll from nuget package 
   
Microsoft.EntityFrameworkCore.Tools
Microsoft.EntityFrameworkCore.SqlServer.Design
Microsoft.EntityFrameworkCore.SqlServer

after adding this 






No comments:

Post a Comment

Rewrite whole Web Site System and Sub System with data migration to new system.

Can you please share me your skype id or whats up number for better communications  my skype id is - jitendra.tech  whats up - +919617741414...