December 2019
Intermediate to advanced
528 pages
11h 19m
English
Let's look at how we might persist this to a SQL Server database using Entity Framework Core:
Install-Package Microsoft.EntityFrameworkCore.SqlServerInstall-Package Microsoft.EntityFrameworkCore.Tools
This installs both the Entity Framework libraries and tools that are required.
public class Product{ public int Id { get; set; } public string Description { get; set; } public int StockCount { get; set; }}
It should sit somewhere visible to your application. I've added mine to a subfolder ...