title: Entity Framework 4 - TPH Inheritance in Features CTP5 (code first) with "IS NULL" discriminator
body: <p>Hey guys,
  I'm trying to create a TPH mapping on a hierarchy where the discriminating clause is the classical "IS NOT NULL" / "IS NULL" case.</p>
  
  <p>Here is the example, database wise:</p>
  
  <pre><code>CREATE TABLE info.EducationTypes
  (
     ID INT NOT NULL PRIMARY KEY,
     Name NVARCHAR(64) NOT NULL,
     FKParentID INT NULL REFERENCES info.EducationTypes(ID)
  )
  </code></pre>
  
  <p>the idea is to have a class hierarchy like the following one:</p>
  
  <pre><code>public abstract class EducationType
  {
      public int ID { get; set; }
      public string Name { get; set; }
  }
  
  public class MainEducationType : EducationType
  {
      public IEnumerable&lt;SubEducationType&gt; SubTypes { get; set; }
  }
  
  public class SubEducationType : EducationType
  {
      public MainEducationType MainType { get; set; }
  }
  </code></pre>
  
  <p>I got this schema "working" in the classic xml model, but I really can't find a way to get it working by using the code first approach. This is what I tried...</p>
  
  <pre><code>var educationType = modelBuilder.Entity&lt;EducationType&gt;();
  educationType.Map&lt;MainEducationType&gt;(m =&gt; m.Requires("FKParentID").HasValue(null));
  educationType.Map&lt;SubEducationType&gt;(m =&gt; m.Requires("FKParentID"));
  </code></pre>
  
  <p>Do you have any suggestion?</p>