Tech Blog

Many to Many Relationship in EF Core

By: Chris Dunn on Tue May 21, 2019 (5 min read)

A many-to-many relationship is one where you have two entities and entity x can have one or more of entity y, and entity y can have one or more of entity x.  Examples of this relationship are Products <-> Orders, BlogPosts <-> Tags, Albums <-> Artists, and in this post Courses <-> Students. In our example let's pretend we're writing course scheduling software for a University.  In that scenario, we might have two models for our Entities, Course and Student declared as fol ...

Copyright 2019 Cidean, LLC. All rights reserved.

Proudly running Umbraco 7. This site is responsive with the help of Foundation 5.