Updating Asp.net MVC to Core
public class Client { [Key] [ForeignKey("Virtual_KEY")] [Column(Order = 0)] public int Id { get; set; } [Key] [Column(Order = 1)] public string Id2 { get; set; } Entity type 'Client' has a composite key that has been defined with data annotations. To set a composite primary key, use fluent API.