Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否有一个设置我可以用来让 ormlite 在执行插入时忽略具有 DB 定义的默认值的列并且我没有为该列提供值?
InsertOnly 完成这项工作
提供一个 API,在您不想插入每个字段的极少数情况下使用 Expression Visitor
db.InsertOnly(new Person { FirstName = "Amy" }, ev => ev.Insert(p => new { p.FirstName })); 插入“人”(“名字”)值(“艾米”)