title: EF 4.2, CodeFirst - Navigation property within a complext type
body: <p>I know I can solve this by pushing everything into a single entity rather than nesting complex types (as they are just 1-1 mappings), but I like the way it groups properties in the generated OM.</p>
  
  <p>I have a Customer entity that contains a complext type "CrmData". The CrmData entity has a complex type of address.</p>
  
  <pre><code>public class Customer {
    [Required]
    public CrmSpecificData CrmData { get; set; }
  }
  [ComplexType]
  public class CrmSpecificData {
    [MaxLength(40)]
    public string FirstName { get; set; }
  
    [MaxLength(80)]
    public string LastName { get; set; }
  
    public Address Address { get; set; }
  }
  [ComplexType]
  public class Address {
    [MaxLength(150)]
    public string Address1 { get; set; }
  
    [MaxLength(150)]
    public string Address2 { get; set; }
  
    [MaxLength(100)]
    public string City { get; set; }
  
    [MaxLength(15)]
    public string PostalCode { get; set; }
  
    public StateProvince StateOrProvince { get; set; }
  
    public virtual CountryRegion CountryOrRegion { get; set; }
  }
  </code></pre>
  
  <p>The StateProvince &amp; CountryRegion types are entities in my DB (similar to how the AdventureWorks sample DB works). The problem is that when EF tries to create the model, it fails with:</p>
  
  <p>The type 'MyCo.Crm.Entities.StateProvince' has already been configured as an entity type. It cannot be reconfigured as a complex type..</p>
  
  <p>I've tried making the StateProvince a complex type but that doesn't resolve the issue. Ideas?</p>
  
  <pre><code>public class StateProvince {
    [Key]
    public int StateProvinceId { get; set; }
  
    [MaxLength(3)]
    public string StateProvinceCode { get; set; }
  
    [MaxLength(50)]
    public string Name { get; set; }
  }
  </code></pre>