Linq submitchanges not updating

Removing columns Removing columns is when most problems will occur.

linq submitchanges not updating-15linq submitchanges not updating-9linq submitchanges not updating-73linq submitchanges not updating-8

You can start with a new instance of the Data Context if the changes in memory are to be discarded.

If our query was like below, then it wouldn’t cause an exception as Phone would never be called.

However, when inserting data we will always get a Sql Exception even if the column was not populated as Linq will try and insert null into the column.

Regenerating our Data Context So, if you are changing the underlying table, updating the Data Context in your system is also required.

In Visual Studio 2008 there are only two ways to update a Data Context.

Leave a Reply