alter table MyTable add constraint DefGetDate DEFAULT GETDATE() FOR myColumn
In edmx, select the column from the entity and set the StoreGeneratedPatern to Computed or Identity.
The available values for StoreGeneratedPatern are:
- None - A value indicating that it is not a server generated property. This is the default value.
- Identity - A value is generated on insert and remains unchanged on update.
- Computed - A value is generated on both insert and update.
The MSDN page regarding this is http://msdn.microsoft.com/en-us/library/system.data.metadata.edm.storegeneratedpattern.aspx
No comments:
Post a Comment