Unable to update the EntitySet because it has a DefiningQuery and no element exists in the element to support the current operation

Este error:

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

Es porque la tabla en la base de datos no tiene clave primaria, hay que crearle almenos una clave primaria a la tabla en la base de datos, actualizar el modelo y fijarse que todas las claves primarias esten correctamente mapeadas en el modelo.

3 comentarios en “Unable to update the EntitySet because it has a DefiningQuery and no element exists in the element to support the current operation

  1. Pingback: C# Lists

  2. Manuel Gomez

    Gracias, por tu post, llevaba bastante rato buscando porque no funcionaba.

    Manuel Gomez
    Medellin – Colombia

Deja un comentario

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *

Este sitio usa Akismet para reducir el spam. Aprende cómo se procesan los datos de tus comentarios.