title: ef error:{"A dependent property in a ReferentialConstraint is mapped to a store-generated column. Column: 'ShippingCardID'."}
body: <p>I work in EF.Xml definition table is ...</p>
  
  <pre><code>    &lt;EntityType Name="ShippingCards"&gt;
        &lt;Key&gt;
          &lt;PropertyRef Name="ShippingCardID" /&gt;
        &lt;/Key&gt;
        &lt;Property Name="ShippingCardID" Type="int" Nullable="false" StoreGeneratedPattern="Identity" /&gt;
        &lt;Property Name="ProducedID" Type="int" /&gt;
        &lt;Property Name="User" Type="int" /&gt;
        &lt;Property Name="Count" Type="int" /&gt;
      &lt;/EntityType&gt;
  </code></pre>
  
  <p>methode is definition</p>
  
  <pre><code>    public void addProduct(Product product)
      {
          ShippingCard sc = new ShippingCard();
          sc.ProducedID = product.ProductID;
          Add(sc);
          context.SaveChanges();
      }
  </code></pre>
  
  <p>When you try to put in the product in the cart breaks my mistake</p>
  
  <p><strong>{"A dependent property in a ReferentialConstraint is mapped to a store-generated column. Column: 'ShippingCardID'."}</strong></p>
  
  <p>InnerError:
  <strong>{"A dependent property in a ReferentialConstraint is mapped to a store-generated column. Column: 'ShippingCardID'."}</strong></p>