title: code first with abstract class, the fk couldn't generated
body: <p>please look at the code below.</p>
  
  <pre><code>class Program
  {
      static void Main(string[] args)
      {
          using (myContext context = new myContext())
          {
              Team t = new Team();
              t.id = 1;
              t.Name = "asd";
              context.teamSet.Add(t);
              context.SaveChanges();
          }
      }
  }
  
  public abstract class Base
  {
      public virtual int id { get; set; }
  }
  
  public abstract class Player : Base
  {
      public virtual string Name { get; set; }
      public virtual int Number { get; set; }
      public virtual Team team { get; set; }
      [ForeignKey("team")]
      public int teamId { get; set; }
  }
  
  public class Team : Base
  {
      public ICollection&lt;Player&gt; Players { get; set; }
      public string Name { get; set; }
  }
  
  public class FootballPlayer : Player
  {
      public double Speed { get; set; }
  }
  
  public class BasketballPlayer : Player
  {
      public double Height { get; set; }
      public double Speed { get; set; }
  }
  
  public class myContext : DbContext
  {
      public DbSet&lt;Player&gt; playerSet { get; set; }
      public DbSet&lt;Team&gt; teamSet { get; set; }
  
      protected override void OnModelCreating(DbModelBuilder modelBuilder)
      {
          modelBuilder.Configurations.Add(new BaseConfiguration()).Add(new PlayerConfiguration()).Add(new TeamConfiguration()).Add(new FootballConfiguration()).Add(new BasketballConfiguration());           
      }
  }
  
  public class BaseConfiguration : EntityTypeConfiguration&lt;Base&gt;
  {
      public BaseConfiguration()
      {
          HasKey(k =&gt; k.id);
          Property(p =&gt; p.id).IsRequired().HasDatabaseGeneratedOption(DatabaseGeneratedOption.None);
      }
  }
  
  public class PlayerConfiguration : EntityTypeConfiguration&lt;Player&gt;
  { 
      public PlayerConfiguration()
      {
          Map(p=&gt;{
              p.MapInheritedProperties();
          p.ToTable("Player");
          });
      }
  }
  
  public class TeamConfiguration : EntityTypeConfiguration&lt;Team&gt;
  {
      public TeamConfiguration()
      {
          Map(p =&gt;
          {
              p.MapInheritedProperties();
              p.ToTable("Team");
          });
      }
  }
  
  public class FootballConfiguration : EntityTypeConfiguration&lt;FootballPlayer&gt;
  {
      public FootballConfiguration()
      {
          ToTable("FootballPlayer");
      }
  }
  
  public class BasketballConfiguration : EntityTypeConfiguration&lt;BasketballPlayer&gt;
  {
      public BasketballConfiguration()
      {
          ToTable("BasketballPlayer");
      }
  }
  </code></pre>
  
  <p>My Player class and Team Class are derived from Based Class, and FootballPlayer and BasketballPlayer are derived from Player. But in the generated database, Player table doesn't contain a FK teamId, it is only a common property. Furthermore, the FootballPlayer and BasketballPlayer tables don't contains the properties which derived from Player class. Anyone can help?</p>