title: Schema specified is not valid. Errors: The relationship not loaded because the type is not available
body: <p>I have the entities Dependency, Product and Access. Dependency is connected to Product and Access. When i try to create a object set of Access with:</p>
  
  <pre><code>this.context.CreateObjectSet&lt;Access&gt;();
  </code></pre>
  
  <p>It's working... but when i try to create a object set of Product i get this error: Schema specified is not valid. Errors: The relationship 'Model.FK_Product_Dependency' was not loaded because the type 'Model.Dependency' is not available.</p>
  
  <p>Any ideas?</p>
  
  <p>OBS: i'm working with Database to Model, and with EF 4.0</p>
  
  <p>POCO Entities:</p>
  
  <pre><code>public class Dependency
  {
      public virtual int Id { get; set; }
      public virtual int IdParent { get; set; }
      public virtual string Name { get; set; }
      public virtual decimal Type { get; set; }
      public virtual Dependency Parent { get; set; }
  }
  
  public class Product
  {
      public virtual int Id { get; set; }
      public virtual int IdDependency { get; set; }
      public virtual decimal Type { get; set; }
      public virtual string Name { get; set; }
      public virtual string Obs { get; set; }
      public virtual Dependency Dependency { get; set; }
  }
  
  public class Access
  {
      public virtual int Id { get; set; }
      public virtual int IdProfile { get; set; }
      public virtual string Name { get; set; }
      public virtual Profile Profile { get; set; }
      public virtual ICollection&lt;Dependency&gt; Dependencies { get; set; }
  }
  </code></pre>