How do you insert/update a column through Linq To SQL and Linq To SQL use the default values? In particular I’m concerned with a timestamp field.
I’ve tried setting that column to readonly and autogenerated, so it stopped trying to put in DateTime.MinValue, but it doesn’t seem to be updating on updates.
The database default value would only insert the value on creating the row. It would do nothing for update, unless you want to add a triggger.
Alternately, you can add a partial method to your DataContext class. Add a new file you your project: