I have an object that has a property:
[Column]
public Binary Image { get; set; }
When the object is saved the first time every this is OK, but when it is modified I get an exception on SubmitChanges:
The data types image and
varbinary(max) are incompatible in the
equal to operator.
What might be the problem here?
Are you getting the, “” exception? The problem is that linq2sql wants to check to make sure it should modify the column before it actually modifies it. I usually don’t care as much and am perfectly happy updating the entire row so I put the
UpdateCheck = UpdateCheck.Nevernamed parameter in myColumnAttributes. I.e.,Then, when I want to save the item, I just do this: