I have a many-to-many relationship between Issues
and Scopes
in my EF Context. In ASP.NET MVC, I bring up an Edit form that allows the user to edit a
**Disclaimer: I am relatively new to EF, take my answer with a bucket of salt.
If this is an edit form, I think your issue object should not be a "new" issue, it should pull the issue out of the data store. As far as I can see by doing:
Issue issue = new Issue { IssueID = id, TSColumn = formIssue.TSColumn };
edmx.Issues.Attach(issue);
you are effectively creating a New Issue with the Id of the one you are trying to edit.
Again, I am here looking for ways to make sense of EF myself. Sometimes I miss my SQL statements.