title: Create child without parent using EntityFramework Core
body: <p>In my ASP.Net core (1.1) Web API I have two models: Task and Feature. Initially I create one or many Tasks and then I can combine few of them to be a Feature.</p>
  
  <p>For this I have written my models as following:</p>
  
  <pre><code>public class User_Task
  {
      [Key]
      public long TaskId { get; set; }
      public string What { get; set; }
  
      [ForeignKey("FeatureId")]
      public long FeatureId { get; set; }
  
      public User_Task()
      {
  
      }
  
  }
  </code></pre>
  
  <p>and Feature:</p>
  
  <pre><code>public class Feature
  {
      [Key]
      public long FeatureId { get; set; }
      public string Analyst_comment { get; set; }
  
      public virtual ICollection&lt;User_Task&gt; Tasks { get; set; }
  
      public Feature()
      {
  
      }
  }
  </code></pre>
  
  <p>Now the problem is: I am not being able to create a task without first creating a Feature- I tried passing featureId as 0 or null for POST request of Tasks but it fails (for null I get bad request and for 0 it throws exception).</p>
  
  <p>What should I modify in my models or controller or repo class to handle this situation?</p>