EF 新增数据时提示it has a DefiningQuery and no <InsertFunction> element exists in the <ModificationFunctionMapping> element

Unable to update the EntitySet 'Users' because it has a DefiningQuery and no <InsertFunction> element exists in the <ModificationFunctionMapping> element to support the current operation.

检查该 Entity 对应的 表是否没有主键,设置表的主键,确保Entity的主键和表的主键一致

posted @ 2016-07-03 14:31  懒懒的小易  阅读(1031)  评论(0编辑  收藏  举报