Context submitchanges is not updating the database
One problem that I can't seem to resolve with the data context is how to update Entities based on POCO objects that didn't originate out of the Data Context.
This series of articles is the best I have found on explaining LINQ data mapping I have come across - very logical, clear and easy to understand.
I am using it as a basis to create my own model which includes an M: M relationship so I have declared an internal class along the lines of the Book Author class in the article.
Everything seems to work well until I call the Submit Changes method to update an M: M relationship at which point I get a SQLException 80131904 - Invalid Object Name.
You apply any number of updates, inserts or deletes.
That are then held as a unit of work, then once you've finished your changes you simply commit them to the database as a single action or roll all of the changes back, maintaining the integrity of your database.
Search for context submitchanges is not updating the database:
For more information, see Customizing Insert, Update, and Delete Operations. foreach (Order ord in query) // Submit the changes to the database. Order ID = 11000 _ Select ord ' Execute the query, and change the column values ' you want to change.