I've created a database that has two tables called Teachers and Courses . A teacher can teach in many courses and a course can have many teachers. I've created the Teacher Courses table to match both. When using the Entity Framework wizard to do the mapping, it did not generate the entity class from the TeacherCurrents table. Instead, both classes have HashSets that represent their lists of Teachers and Courses. The problem is that in the application, when I try to enroll a Teacher in a Course or enroll a Course for a Teacher, it may be that the Teacher is already related to the Course and in this case, an exception is thrown. The question is: how can I recover all Teachers from a Course or vice versa using LINQ to Entities? If I can get them back, I can handle the problem of ambiguous inscriptions. Thank you in advance.