之前用DBLinq想在sqlite环境使用LINQ to SQL, 但一直有错误(DataContext.SubmitChanges()遇到一个exception)
昨天用了sql server后便成功了.
mysql中primary key auto_increment对应sql server中的identity.
在model class中要对主键属性设置ColumnAttribute的isPrimaryKey为true, 还需要设置isDbGenerated为true, 对应auto_increment