I have several classes that I need to derive from a common base class which holds an Id. Ignoring the all but one of these for the moment, let\'s say we have:
I remember when I used to do EF I would create a table with Identity and in the class I would attribute the id column with
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
so I am assuming that your code should be
modelBuilder.Entity()
.Property(c => c.Id)
.HasDatabaseGeneratedOption(DatabaseGeneratedOption.Identity);