Support Composite Key in ASP.NET Web API OData

The default EntitySetController doesn't support composite keys. So if you have composite key models, you need some additional work. Here is an example about how to do that.The model is simple:public class Person { [Key] public string FirstName { get; set; } [Key]

C# (686.3 KB)
4 Star
1,127 times
Add to favorites
E-mail Twitter Digg Facebook