Learn how to use the Include method in Entity Framework Core to create a one to many relationship query.
This tutorial will involve adding a new entity which will be populated using data seeding and will use EF Core migrations to add it to the SQL Server database.
We'll then use ASP.NET Core Web API endpoints to write LINQ queries that use a one to many relationship. We'll also have a look at inserting and updating a record which has a foreign key.
► This is part 5 of our Get started with EF Core course. View the full playlist:
• Get started with EF Core - Full course
💻 Download the code example💻
https://www.roundthecode.com/dotnet-c...
📖 Learn .NET and C# with our online courses 📖
https://www.roundthecode.com/dotnet-c...
👨💻Take our .NET and C# coding challenges👨💻
https://www.roundthecode.com/dotnet-c...
► Chapters
0:00 What we'll cover
0:14 Creating a relationship entity
1:02 Relationship entity type configuration
2:47 Relationship migration
4:18 Insert & update using a relationship
6:05 Query using a relationship
7:56 Learn more about EF Core
#efcore #entityframework #entityframeworkcore
Смотрите видео Include method for one to many relationships in EF Core онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Round The Code 18 Февраль 2024, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 1,334 раз и оно понравилось 19 людям.