Entity Framework Code First: MultiLevel TPC Inheritance With Relationships in the Middle Level
===

I am using TPC inheritance to map a complex object model to an existing database. I am running into an issue when I create a relationship in the middle level of my inheritance structure.

    public class ParentClass
    {
    }
    
    public class MiddleClass : ParentClass
    {
        public Int64 RelationshipId;
        public Relationship Relationship;
    }

    public class ChildClass1 : MiddleClass
    {
    }

    public class ChildClass2: MiddleClass
    {
    }

    public class Relationship
    {
        public string RelationshipInfo { get; set; }
    }

    public class MyEntities : DbContext
    {
        public DbSet<ParentClass> Parents
        public override void OnModelCreating(DbModelBuilder modelBuilder)
        {
            modelBuilder.Entity<ChildClass1>.Map(m => m.MapInheritedProperties);
            modelBuilder.Entity<ChildClass2>.Map(m => m.MapInheritedProperties);

            modelBuilder.Entity<MiddleClass>.HasRequired(mc => mc.Relationship).WithMany().HasForeignKey(mc => mc.RelationshipId);
        }
    }

My model will work until I add the `modelBuilder.Entity<MiddleClass>.HasRequired(mc => mc.Relationship).WithMany().HasForeignKey(mc => mc.RelationshipId);` line. Do I have to map this relationship to every child?

The error I receive is *'The type "MiddleClass" cannot be mapped as defined because it maps inherited properties from types that use entity splitting or another form of inheritance.'*