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

解决方案:

  1. 右键单击edmx文件,选择Open with(打开方式),XML editor(XML编辑器)
  2. 在edmx:StorageModels元素中找到实体
  3. 完全删除DefiningQuery
  4. 重命名store:Schema="dbo"Schema="dbo"(否则,代码将生成错误,说明名称无效)

猜你喜欢

转载自www.cnblogs.com/xiewei123/p/11294465.html