title: Insert value into identity column in Core 2.2
body: <p>Trying to seed database in MSSQL server. 'Id' column is set to identity. I fail to understand why EF needs data for 'Id:</p>
  
  <pre><code>public class Location
  {
      public int? Id { get; set; }
  
      public string Name { get; set; }
  
      public IList&lt;Office&gt; Offices { get; set; }
  
  }
  </code></pre>
  
  <p>... fluent API:</p>
  
  <pre><code>modelBuilder.Entity&lt;Location&gt;()
       .HasKey(k =&gt; k.Id);
  
  modelBuilder.Entity&lt;Location&gt;()
       .Property(p =&gt; p.Id)
       .UseSqlServerIdentityColumn()
       .ValueGeneratedOnAdd();
  
  modelBuilder.Entity&lt;Location&gt;()
       .HasData(
              new Location() { Name = "Sydney" },
              new Location() { Name = "Melbourne" },
              new Location() { Name = "Brisbane" }
      );
  </code></pre>
  
  <p>... as far as I understand 'Id' doesn't need to be provided if it's generated by server on insert. Why do I get the messages about not providing Id ...</p>