title: Silverlight + RIA: problem editing entity
body: <p>I have a Silverlight 4 application with EntityFramework as data layer.</p>
  
  <p>There are two entities: Customer and Products. When I get customer from a database, the related products are also read, as I added related 'Include' attribute in customer's metadata and call Include method in get query:</p>
  
  <pre><code>public IQueryable&lt;customer&gt; GetCustomerSetById(int customerId)
  {
      return this.ObjectContext.CustomerSet
          .Include(o =&gt; o.Products)
          .Where(o =&gt; o.Id = customerId);
  }
  </code></pre>
  
  <p>The problem that when I change any property in customer's product I get this exception:</p>
  
  <blockquote>
    <p>This EntitySet of Type
    'MyApp.Web.Models.Product' does not
    support the 'Edit' operation.</p>
  </blockquote>
  
  <p>But everything works if I read customer products directly, e.g. not through customer entity (CustomerContext) , but via product one (ProductContext).</p>
  
  <p>Also there is the IsReadOnly=true property in a product entity.</p>
  
  <p>UPDATE:</p>
  
  <p>I have all CUD operations and also marked all of them with related Insert, Update and Delete attributes. Otherwise it wouldn't work at all, but it works for me in some cases as I wrote above.</p>
  
  <p>Any ideas?</p>